:root {
  --seo-font-sans: "Noto Sans TC", "PingFang TC", "Microsoft JhengHei", -apple-system,
    BlinkMacSystemFont, "Segoe UI", Arial, sans-serif;
  --seo-ink: #f8fbff;
  --seo-muted: rgba(248, 251, 255, 0.82);
  --seo-accent: #8edfd4;
  --seo-accent-strong: #55cbbb;
  --seo-surface: #112936;
  --seo-surface-deep: #08171f;
  --seo-focus: #ffe59a;
}

html {
  font-family: var(--seo-font-sans);
  -webkit-text-size-adjust: 100%;
}

body,
button,
input,
select,
textarea,
.b-text,
.b-text p,
.b-text li,
.b-text h1,
.b-text h2,
.b-text h3,
.b-text h4,
.sit,
.it,
.menu-font {
  font-family: var(--seo-font-sans) !important;
  text-rendering: optimizeLegibility;
}

.seo-skip-link {
  position: fixed;
  top: 0.75rem;
  left: 0.75rem;
  z-index: 100000;
  padding: 0.7rem 1rem;
  border-radius: 0.5rem;
  color: #082126;
  background: var(--seo-focus);
  font: 700 1rem/1.2 var(--seo-font-sans);
  transform: translateY(-180%);
  transition: transform 160ms ease;
}

.seo-skip-link:focus {
  transform: translateY(0);
}

/* 全站頁首品牌與選單：鎖定相同字型、字級與字重。 */
.logo-text-cell,
.menu-item-text,
#menu-submit,
.more-text {
  font-family: var(--seo-font-sans) !important;
  font-style: normal !important;
  letter-spacing: 0.01em !important;
  text-transform: none !important;
}

.logo-text-cell {
  font-size: 16px !important;
  font-weight: 700 !important;
  line-height: 1.45 !important;
}

.menu-item-text,
#menu-submit,
.more-text {
  font-size: 15px !important;
  font-weight: 600 !important;
  line-height: 1.45 !important;
}

.menu-item:focus-visible,
.logo-link:focus-visible,
.seo-hero-actions a:focus-visible,
.seo-breadcrumb a:focus-visible {
  outline: 3px solid var(--seo-focus) !important;
  outline-offset: 4px;
}

/* 每一頁共用的上方主標區。 */
.seo-page-hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  color: var(--seo-ink);
  background:
    radial-gradient(circle at 82% 18%, rgba(142, 223, 212, 0.25), transparent 31%),
    radial-gradient(circle at 12% 82%, rgba(114, 147, 216, 0.2), transparent 34%),
    linear-gradient(135deg, var(--seo-surface-deep), var(--seo-surface));
}

.seo-page-hero::after {
  position: absolute;
  right: -7rem;
  bottom: -9rem;
  z-index: -1;
  width: 20rem;
  height: 20rem;
  border: 1px solid rgba(255, 255, 255, 0.13);
  border-radius: 50%;
  box-shadow:
    0 0 0 2.5rem rgba(255, 255, 255, 0.025),
    0 0 0 5rem rgba(255, 255, 255, 0.018);
  content: "";
}

.seo-hero-inner {
  width: min(100% - 2.5rem, 1040px);
  margin-inline: auto;
  padding-block: clamp(3.5rem, 8vw, 7.5rem);
}

.seo-breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  align-items: center;
  margin: 0 0 1.25rem;
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.88rem;
  line-height: 1.5;
}

.seo-breadcrumb a {
  color: var(--seo-accent);
  text-decoration: none;
}

.seo-eyebrow {
  margin: 0 0 0.85rem;
  color: var(--seo-accent);
  font-size: clamp(0.82rem, 1.6vw, 0.95rem);
  font-weight: 800;
  line-height: 1.5;
  letter-spacing: 0.08em;
}

.seo-page-hero h1 {
  max-width: 920px;
  margin: 0;
  color: var(--seo-ink);
  font-family: var(--seo-font-sans) !important;
  font-size: clamp(2rem, 5vw, 4rem) !important;
  font-weight: 800 !important;
  line-height: 1.16 !important;
  letter-spacing: -0.025em !important;
  text-wrap: balance;
}

.seo-hero-description {
  max-width: 820px;
  margin: 1.25rem 0 0;
  color: var(--seo-muted);
  font-size: clamp(1rem, 2vw, 1.18rem);
  line-height: 1.9;
}

.seo-hero-note {
  max-width: 820px;
  margin: 0.85rem 0 0;
  color: rgba(255, 255, 255, 0.66);
  font-size: 0.9rem;
  line-height: 1.75;
}

.seo-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin-top: 1.75rem;
}

.seo-hero-actions a {
  display: inline-flex;
  min-height: 46px;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.15rem;
  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 999px;
  color: #fff;
  font-size: 0.96rem;
  font-weight: 750;
  line-height: 1.35;
  text-decoration: none;
  transition: background-color 160ms ease, border-color 160ms ease, transform 160ms ease;
}

.seo-hero-actions a:first-child {
  border-color: var(--seo-accent-strong);
  color: #06221f;
  background: var(--seo-accent);
}

.seo-hero-actions a:hover {
  border-color: var(--seo-accent);
  background-color: rgba(142, 223, 212, 0.14);
  transform: translateY(-1px);
}

.seo-hero-actions a:first-child:hover {
  background: #b2eee6;
}

/* 原有 Webnode 內容也使用相同字體，避免頁首以下突然跳字型。 */
.b-text h1,
.b-text h2,
.b-text h3,
.claim .sit-c {
  font-family: var(--seo-font-sans) !important;
  letter-spacing: normal !important;
}

.b-text p,
.b-text li {
  overflow-wrap: anywhere;
  line-height: 1.85;
}

.s-f-cr {
  line-height: 1.7;
}

@media (max-width: 768px) {
  .seo-hero-inner {
    width: min(100% - 2rem, 1040px);
    padding-block: 3.25rem;
  }

  .seo-page-hero h1 {
    font-size: clamp(2rem, 10vw, 3rem) !important;
    line-height: 1.22 !important;
  }

  .seo-hero-description {
    line-height: 1.8;
  }

  .seo-hero-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .seo-hero-actions a {
    width: 100%;
  }

  .logo-text-cell {
    font-size: 15px !important;
  }

  .menu-item-text,
  #menu-submit,
  .more-text {
    font-size: 15px !important;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}

/* =========================================================
   2026-10 手機版修正
   原因：Webnode 主題字型 Metropolis 搬到 Netlify 後沒有任何
   @font-face 載入，瀏覽器改用字型清單中的 Apple/Noto Color
   Emoji 來畫數字與空白，造成「2 0 1 8」數字變淡、英文字間
   距被撐開、文字對不齊。這裡把整站字型統一改回系統中文字型。
   ========================================================= */
:root {
  --seo-font-sans: "Noto Sans TC", "PingFang TC", "Microsoft JhengHei", "Heiti TC",
    -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Arial, sans-serif,
    "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji";
}

.t,
.t *:not(.search-bar-submit):not(svg):not(svg *) {
  font-family: var(--seo-font-sans) !important;
}

.snowflake {
  font-family: "Apple Color Emoji", "Segoe UI Emoji", "Noto Color Emoji", sans-serif !important;
}

html,
body {
  overflow-x: clip;
}

img,
video,
iframe {
  max-width: 100%;
}

/* H1 依「｜」分段換行，避免在詞中間斷開 */
.seo-h1-part {
  display: inline-block;
}

/* About：個人大頭照（原本 3:4 照片塞在 1:1 框內被縮小） */
.seo-portrait {
  width: 100%;
  max-width: 460px;
  margin-inline: auto !important;
}

.seo-portrait .b-img-c {
  overflow: hidden;
  border-radius: 18px;
  box-shadow: 0 18px 40px rgba(0, 0, 0, 0.35);
}

.seo-portrait img {
  object-fit: cover !important;
  object-position: center 30%;
}

/* About：認證徽章不需要佔滿整個寬度 */
.seo-badge {
  max-width: 280px;
  margin-inline: auto !important;
}

/* 頁尾免責聲明：避免英文被撐開 */
.s-f,
.s-f * {
  letter-spacing: normal !important;
  word-spacing: normal !important;
}

@media (max-width: 599px) {
  .seo-page-hero h1 {
    font-size: clamp(1.75rem, 7.6vw, 2.4rem) !important;
    line-height: 1.3 !important;
  }

  .seo-eyebrow {
    letter-spacing: 0.04em;
  }

  /* 內文字級：原本手機上有 22～24px 內文，閱讀節奏過鬆 */
  .b-text p,
  .b-text li {
    font-size: 16px !important;
    line-height: 1.8 !important;
  }

  .b-text p font,
  .b-text li font {
    font-size: inherit !important;
  }

  .b-text h1 {
    font-size: 1.75rem !important;
    line-height: 1.3 !important;
  }

  .b-text h2 {
    font-size: 1.35rem !important;
    line-height: 1.4 !important;
  }

  .b-text h3 {
    font-size: 1.12rem !important;
    line-height: 1.5 !important;
  }

  /* 中英混排長字串（網址、Email）不撐破版面 */
  .b-text,
  .b-text * {
    overflow-wrap: anywhere;
  }

  /* 頁尾免責聲明：最小 12px（Google 行動版易讀標準），靠左對齊 */
  .s-f-l,
  .s-f-l *,
  .s-f-cr,
  .s-f-cr * {
    font-size: 12px !important;
    line-height: 1.7 !important;
    text-align: left !important;
  }

  .seo-portrait {
    max-width: min(100%, 420px);
  }

  .seo-badge {
    max-width: 200px;
  }
}

/* 桌機版：原主題把頁尾免責聲明固定在左側選單底部，
   螢幕高度 768px 以上就會蓋住選單。沿用主題原本給「矮螢幕」的
   版型，一律把頁尾放到右側內容區最下方。 */
@media screen and (min-width: 56.25em) {
  .l-sidebar .l-w {
    grid-template-areas: "a b" "a b" "a c" !important;
  }

  .l-sidebar .l-f {
    position: relative !important;
    inset: auto !important;
    width: 100% !important;
    height: auto !important;
    float: none !important;
    clear: both !important;
    z-index: 0 !important;
  }

  .l-sidebar .l-f .s-f-l,
  .l-sidebar .l-f .s-f-l * {
    text-align: left !important;
  }
}
