/* ==========================================================================
   超群智財權事務所 exctm.com — 全站樣式
   沿用舊站視覺：主色青綠 #0c8d93、深青 #0a5258、白底灰字
   無框架、無外部字型（系統字型），以速度與可讀性為優先
   ========================================================================== */

:root {
    --c-primary: #0c8d93;
    --c-primary-dark: #0a5258;
    --c-primary-light: #e6f4f5;
    --c-accent: #fdd000;
    --c-text: #2b2f33;
    --c-muted: #6b7278;
    --c-line: #e3e7ea;
    --c-bg-soft: #f4f6f7;
    --c-dark: #1d2326;
    --c-line-green: #06c755;
    --radius: 6px;
    --shadow: 0 6px 24px rgba(16, 40, 44, .08);
    --container: 1180px;
    --font: -apple-system, BlinkMacSystemFont, "PingFang TC", "Noto Sans TC", "Microsoft JhengHei", "Segoe UI", Roboto, sans-serif;
    --font-serif: "Noto Serif TC", "Songti TC", "PMingLiU", Georgia, serif;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; font-family: var(--font); font-size: 16px; line-height: 1.8; color: var(--c-text); background: #fff; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--c-primary); text-decoration: none; }
a:hover { color: var(--c-primary-dark); text-decoration: underline; }
h1, h2, h3, h4 { line-height: 1.4; color: var(--c-dark); margin: 0 0 .6em; }
p { margin: 0 0 1em; }
ul, ol { padding-left: 1.3em; }
:focus-visible { outline: 3px solid var(--c-accent); outline-offset: 2px; }

.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 20px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: -999px; top: 0; background: var(--c-primary); color: #fff; padding: 8px 16px; z-index: 1000; }
.skip-link:focus { left: 0; }

/* ---------- 按鈕 ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .4em; padding: .75em 1.6em; border-radius: var(--radius); font-weight: 600; border: 2px solid transparent; transition: .2s; line-height: 1.3; }
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn--primary { background: var(--c-primary); color: #fff; }
.btn--primary:hover { background: var(--c-primary-dark); color: #fff; }
.btn--outline { border-color: var(--c-primary); color: var(--c-primary); background: #fff; }
.btn--outline:hover { background: var(--c-primary); color: #fff; }
.btn--line { background: var(--c-line-green); color: #fff; }
.btn--line:hover { background: #05a849; color: #fff; }
.btn--light { background: #fff; color: var(--c-primary-dark); }
.btn--light:hover { color: var(--c-primary-dark); }
.btn--ghost { border-color: rgba(255,255,255,.7); color: #fff; }
.btn--ghost:hover { background: rgba(255,255,255,.12); color: #fff; }

/* ---------- 頁首 ---------- */
.topbar { background: var(--c-primary); color: #fff; font-size: 13px; }
.topbar__inner { display: flex; justify-content: space-between; align-items: center; min-height: 36px; }
.topbar__lang a { color: #fff; margin-left: 16px; opacity: .85; }
.topbar__lang a[aria-current] { opacity: 1; font-weight: 700; }
.header__main { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding-top: 14px; padding-bottom: 14px; }
.logo img { width: 180px; height: auto; }
.header__contact { display: flex; gap: 24px; font-size: 14px; }
.header__item { display: inline-flex; align-items: center; gap: 6px; color: var(--c-muted); }
.header__item svg { width: 20px; height: 20px; color: var(--c-primary); }
.header__tel { font-weight: 700; color: var(--c-primary-dark); }

.site-nav { border-top: 1px solid var(--c-line); border-bottom: 1px solid var(--c-line); background: #fff; position: sticky; top: 0; z-index: 50; }
.site-nav__inner { display: flex; justify-content: space-between; align-items: center; }
.menu { display: flex; list-style: none; margin: 0; padding: 0; }
.menu > li { position: relative; }
.menu > li > a { display: block; padding: 14px 18px; color: #555; font-weight: 600; }
.menu > li > a:hover, .menu > li > a[aria-current] { color: var(--c-primary); text-decoration: none; }
.menu > li > a[aria-current] { box-shadow: inset 0 -3px 0 var(--c-primary); }
.menu__reviews { font-weight: 700; color: var(--c-primary); }
.sub-toggle { display: none; }
.submenu { display: none; position: absolute; top: 100%; left: 0; background: #fff; box-shadow: var(--shadow); border-top: 3px solid var(--c-primary); padding: 18px 22px; gap: 32px; min-width: 420px; }
.has-sub:hover .submenu, .has-sub:focus-within .submenu { display: flex; }
.submenu__title { font-size: 13px; color: var(--c-muted); margin: 0 0 6px; font-weight: 700; }
.submenu ul { list-style: none; padding: 0; margin: 0; columns: 2; column-gap: 24px; }
.submenu__col:last-child ul { columns: 1; }
.submenu a { display: block; padding: 4px 0; color: var(--c-text); font-size: 15px; white-space: nowrap; }
.nav-toggle { display: none; }

/* ---------- 首頁 Hero ---------- */
.hero { position: relative; color: #fff; min-height: 520px; display: flex; align-items: center; overflow: hidden; background: var(--c-primary-dark); }
.hero__bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
/* 背景影片：圖片先顯示（首屏最快），影片可播放後淡入覆蓋 */
.hero__video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity .8s ease; }
.hero__video.is-playing { opacity: 1; }
.hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(10,40,44,.78) 0%, rgba(10,40,44,.35) 60%, rgba(10,40,44,.1) 100%); }
.hero .container { position: relative; z-index: 1; }
.hero__eyebrow { font-size: 15px; letter-spacing: .1em; opacity: .9; margin-bottom: .4em; }
.hero__title { color: #fff; font-size: clamp(28px, 4.2vw, 46px); font-weight: 800; margin-bottom: .4em; }
.hero__lead { font-size: clamp(16px, 1.6vw, 19px); max-width: 640px; opacity: .95; }
.hero__btns { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 1.6em; }

/* ---------- 區塊 ---------- */
.section { padding: 80px 0; }
.section--soft { background: var(--c-bg-soft); }
.section--dark { background: var(--c-dark) var(--bg, none) center/cover; color: #fff; position: relative; }
.section--dark h2, .section--dark h3 { color: #fff; }
.section__head { margin-bottom: 36px; }
.section__eyebrow { color: var(--c-primary); font-size: 14px; letter-spacing: .08em; margin: 0 0 .2em; }
.section--dark .section__eyebrow { color: #9fd9dc; }
.section__title { font-size: clamp(24px, 3vw, 34px); font-weight: 800; }
.section__desc { color: var(--c-muted); max-width: 760px; }
.section--dark .section__desc { color: #cfd8da; }
.center { text-align: center; }
.center .section__desc { margin-left: auto; margin-right: auto; }

/* 服務特色 + 數據 */
.feature { display: grid; grid-template-columns: 1fr 1fr; gap: 30px; align-items: stretch; }
.feature__card { display: grid; grid-template-columns: 2fr 3fr; background: #fff; box-shadow: var(--shadow); }
.feature__card img { width: 100%; height: 100%; object-fit: cover; }
.feature__text { padding: 32px; }
.feature__text ul { padding-left: 1.1em; color: var(--c-muted); }
.stats { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.stats__item { background: var(--c-primary); color: #fff; padding: 28px 24px; display: flex; flex-direction: column; justify-content: flex-end; min-height: 170px; }
.stats__item--1, .stats__item--2 { background: var(--c-primary-dark); }
.stats__num { font-family: var(--font-serif); font-size: 40px; line-height: 1.1; font-weight: 700; }
.stats__num small { font-size: 20px; margin-left: 2px; }
.stats__label { font-size: 14px; opacity: .9; margin-top: 6px; }

/* 卡片 */
.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.card { background: #fff; box-shadow: var(--shadow); display: flex; flex-direction: column; border-radius: var(--radius); overflow: hidden; transition: .2s; }
.card:hover { transform: translateY(-3px); box-shadow: 0 12px 30px rgba(16,40,44,.12); }
.card__img img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; }
.card__body { padding: 20px 22px 22px; display: flex; flex-direction: column; flex: 1; }
.card__title { font-size: 18px; margin: 6px 0 8px; }
.card__title a { color: var(--c-dark); }
.card__excerpt { color: var(--c-muted); font-size: 14px; flex: 1; }
.card__more { font-size: 14px; font-weight: 600; }
.tag { display: inline-block; align-self: flex-start; font-size: 12px; background: var(--c-primary-light); color: var(--c-primary-dark); padding: 2px 10px; border-radius: 20px; font-weight: 600; }

/* 代表客戶 */
.clients { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(6, 1fr); gap: 18px; }
.clients li { border: 1px solid rgba(255,255,255,.25); aspect-ratio: 1; display: flex; align-items: center; justify-content: center; padding: 10px; }
.clients img { width: 100%; height: auto; }

/* CTA */
.cta { background: linear-gradient(120deg, var(--c-primary-dark), var(--c-primary)); color: #fff; padding: 56px 0; }
.cta__inner { display: flex; align-items: center; justify-content: space-between; gap: 30px; flex-wrap: wrap; }
.cta__title { color: #fff; font-size: 26px; }
.cta p { margin: 0; opacity: .92; max-width: 560px; }
.cta__btns { display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------- 內頁 ---------- */
.page-banner { background: var(--c-primary-dark) var(--banner) center/cover no-repeat; color: #fff; padding: 64px 0; position: relative; }
.page-banner::before { content: ""; position: absolute; inset: 0; background: rgba(6, 50, 54, .55); }
.page-banner .container { position: relative; }
.page-banner__sub { margin: 0; letter-spacing: .1em; opacity: .85; font-size: 14px; }
.page-banner__title { color: #fff; font-size: clamp(26px, 3.4vw, 40px); margin: 0; }
.breadcrumb { background: var(--c-bg-soft); font-size: 14px; }
.breadcrumb ol { list-style: none; display: flex; flex-wrap: wrap; margin: 0; padding: 10px 0; }
.breadcrumb li + li::before { content: "›"; margin: 0 8px; color: var(--c-muted); }
.breadcrumb [aria-current] { color: var(--c-muted); }

.layout { display: grid; grid-template-columns: minmax(0, 1fr) 300px; gap: 48px; align-items: start; }
.sidebar { position: sticky; top: 70px; display: grid; gap: 20px; }
.box { background: var(--c-bg-soft); padding: 22px; border-radius: var(--radius); }
.box h2, .box h3 { font-size: 17px; }
.box ul { list-style: none; padding: 0; margin: 0; }
.box li { padding: 4px 0; border-bottom: 1px dashed var(--c-line); }
.box li:last-child { border: 0; }
.box--primary { background: var(--c-primary); color: #fff; }
.box--primary h2, .box--primary h3 { color: #fff; }
.box--primary .btn { width: 100%; margin-top: 8px; }

/* 文章內文 */
.prose { font-size: 17px; }
.prose h2 { font-size: 23px; margin-top: 1.8em; padding-left: 12px; border-left: 4px solid var(--c-primary); }
.prose h3 { font-size: 19px; margin-top: 1.5em; }
.prose figure { margin: 1.6em 0; }
.prose figure img { border-radius: var(--radius); }
.prose li { margin-bottom: .5em; }
.lead { font-size: 18px; color: var(--c-muted); }
.article-cover { margin-bottom: 28px; border-radius: var(--radius); overflow: hidden; }
.article-meta { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; color: var(--c-muted); font-size: 14px; margin-bottom: 20px; }
.post-nav { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 48px; border-top: 1px solid var(--c-line); padding-top: 24px; }
.post-nav a { display: block; padding: 14px 18px; background: var(--c-bg-soft); border-radius: var(--radius); }
.post-nav small { display: block; color: var(--c-muted); }
.post-nav__next { text-align: right; }

/* 重點摘要（GEO：給 AI 與讀者的快速答案） */
.summary { background: var(--c-primary-light); border-left: 4px solid var(--c-primary); padding: 18px 22px; border-radius: 0 var(--radius) var(--radius) 0; margin-bottom: 28px; }
.summary h2 { font-size: 18px; margin: 0 0 8px; border: 0; padding: 0; }
.summary ul { margin: 0; }

/* 制度表格 */
.spec { width: 100%; border-collapse: collapse; margin: 0 0 28px; font-size: 16px; }
.spec th, .spec td { border: 1px solid var(--c-line); padding: 12px 16px; text-align: left; vertical-align: top; }
.spec th { background: var(--c-primary); color: #fff; width: 26%; white-space: nowrap; }
.spec tr:nth-child(even) td { background: var(--c-bg-soft); }
.spec td ul { margin: 0; padding-left: 1.1em; }
.spec td p:last-child { margin: 0; }

/* FAQ */
.faq { border-top: 1px solid var(--c-line); }
.faq details { border-bottom: 1px solid var(--c-line); }
.faq summary { cursor: pointer; padding: 16px 36px 16px 0; font-weight: 700; position: relative; list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 6px; top: 12px; font-size: 22px; color: var(--c-primary); }
.faq details[open] summary::after { content: "−"; }
.faq__a { padding: 0 0 16px; color: #444; }

/* 商標知識 */
.kb-intro { max-width: 820px; margin-bottom: 24px; }
.kb-cats { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 16px; }
.kb-cats a { display: inline-flex; align-items: center; gap: 8px; padding: 8px 16px; border: 1px solid var(--c-primary); border-radius: 24px; color: var(--c-primary-dark); font-weight: 600; text-decoration: none; }
.kb-cats a:hover { background: var(--c-primary-light); }
.kb-cats span { font-size: 12px; background: var(--c-primary); color: #fff; border-radius: 10px; padding: 0 7px; }
.kb-group { padding-top: 32px; scroll-margin-top: 90px; }
.kb-group h2 { font-size: 24px; padding-left: 12px; border-left: 4px solid var(--c-primary); margin-bottom: 6px; }
.kb-group__desc { color: var(--c-muted); margin-bottom: 12px; }
.kb-list { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 32px; }
.kb-list li { padding: 14px 0; border-bottom: 1px solid var(--c-line); }
.kb-list a { font-weight: 700; font-size: 17px; }
.kb-list p { margin: 4px 0 0; color: var(--c-muted); font-size: 14px; }
.toc { background: var(--c-bg-soft); border-radius: var(--radius); padding: 16px 22px; margin-bottom: 28px; }
.toc__title { font-weight: 700; margin: 0 0 6px; }
.toc ol { margin: 0; padding-left: 1.4em; }
.toc li { padding: 2px 0; }
.kb-article .prose h2, .kb-article .prose h3 { scroll-margin-top: 90px; }
.refs { font-size: 15px; }
.prose > .lead, .hub-lead { color: var(--c-text); font-size: 17px; line-height: 1.9; margin-bottom: 24px; }
.hub-table { min-width: 860px; }
.hub-table td, .hub-table th { font-size: 15px; padding: 10px 12px; }
.hub-table thead th { width: auto; }
.hub-table tbody th { background: var(--c-primary-light); width: 90px; white-space: nowrap; }
.hub-table tbody th a { color: var(--c-primary-dark); font-weight: 700; }
.hub-table td:nth-child(2), .hub-table td:nth-child(4) { white-space: nowrap; }
/* ---------- 內文表格（商標知識、國家指南、總覽頁共用；.spec 為國家制度表，另有樣式） ---------- */
.prose table:not(.spec) { width: 100%; border-collapse: separate; border-spacing: 0; margin: 8px 0 28px; font-size: 15px; line-height: 1.7; border: 1px solid var(--c-line); border-radius: var(--radius); overflow: hidden; background: #fff; }
.prose table:not(.spec) th, .prose table:not(.spec) td { padding: 12px 16px; text-align: left; vertical-align: top; border-bottom: 1px solid var(--c-line); }
.prose table:not(.spec) td + td, .prose table:not(.spec) th + th { border-left: 1px solid var(--c-line); }
.prose table:not(.spec) thead th { background: var(--c-primary); color: #fff; font-weight: 700; white-space: nowrap; border-bottom: 0; }
.prose table:not(.spec) thead th + th { border-left-color: rgba(255,255,255,.25); }
.prose table:not(.spec) tbody tr:last-child td { border-bottom: 0; }
.prose table:not(.spec) tbody tr:nth-child(even) td { background: var(--c-bg-soft); }
.prose table:not(.spec) tbody td:first-child { background: var(--c-primary-light) !important; color: var(--c-primary-dark); font-weight: 700; white-space: nowrap; }
/* 流程表：第一欄自動加圓形步驟編號，最後一欄（時間）強調 */
.prose table.tbl-steps tbody { counter-reset: step; }
.prose table.tbl-steps tbody tr { counter-increment: step; }
.prose table.tbl-steps tbody td:first-child::before { content: counter(step); display: inline-flex; align-items: center; justify-content: center; width: 24px; height: 24px; margin-right: 10px; border-radius: 50%; background: var(--c-primary); color: #fff; font-size: 13px; vertical-align: 1px; }
.prose table.tbl-steps tbody td:last-child { color: var(--c-primary-dark); font-weight: 600; white-space: nowrap; }
/* 比較表：兩個比較對象各用一種底色 */
.prose table.tbl-compare thead th:nth-child(3) { background: #3e5566; }
.prose table.tbl-compare tbody td:nth-child(2) { background: #eef8f8 !important; }
.prose table.tbl-compare tbody td:nth-child(3) { background: #f1f4f7 !important; }
@media (max-width: 768px) {
    .prose table:not(.spec) { display: block; overflow-x: auto; -webkit-overflow-scrolling: touch; }
    .prose table:not(.spec) th, .prose table:not(.spec) td { min-width: 120px; }
}
.kb-note { font-size: 14px; color: var(--c-muted); margin-top: 32px; padding-top: 16px; border-top: 1px dashed var(--c-line); }
@media (max-width: 768px) {
    .kb-list { grid-template-columns: 1fr; }
}

/* 國家卡片 */
.country-grid { list-style: none; padding: 0; margin: 0 0 40px; display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.country-grid a { display: block; padding: 18px; border: 1px solid var(--c-line); border-radius: var(--radius); background: #fff; color: var(--c-dark); transition: .2s; height: 100%; }
.country-grid a:hover { border-color: var(--c-primary); box-shadow: var(--shadow); text-decoration: none; }
.country-grid strong { display: block; font-size: 17px; }
.country-grid span { font-size: 13px; color: var(--c-muted); }
.country-grid .country-grid__time { display: block; color: var(--c-primary-dark); font-weight: 600; margin: 2px 0 4px; }

/* 服務 */
.services { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.service { padding: 30px; background: #fff; border-top: 4px solid var(--c-primary); box-shadow: var(--shadow); display: flex; flex-direction: column; }
/* 卡片底部按鈕：margin-top:auto 讓三張卡片的按鈕對齊在同一高度（說明文字長短不同時也一樣） */
.service__foot { margin-top: auto; padding-top: 20px; text-align: center; }
.service__foot .btn { font-size: 15px; padding: .6em 1.4em; }
.service h3 { font-size: 20px; }
.service__img { width: calc(100% + 60px); max-width: none; margin: -30px -30px 22px; aspect-ratio: 16 / 10; object-fit: cover; }
.service ul { color: var(--c-muted); padding-left: 1.1em; margin: 0; }
.steps { list-style: none; counter-reset: step; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(5, 1fr); gap: 16px; }
.steps li { counter-increment: step; background: #fff; padding: 24px 20px; border-radius: var(--radius); box-shadow: var(--shadow); position: relative; }
.steps li::before { content: "Step " counter(step); display: block; color: var(--c-primary); font-weight: 800; font-size: 14px; margin-bottom: 6px; }
.steps h3 { font-size: 18px; margin-bottom: 6px; }
.steps p { font-size: 14px; color: var(--c-muted); margin: 0; }
.quote { display: flex; gap: 24px; align-items: center; background: var(--c-primary-light); padding: 28px; border-radius: var(--radius); margin-top: 36px; }
.quote img { width: 110px; border-radius: 50%; flex-shrink: 0; }
.quote blockquote { margin: 0; font-size: 18px; font-family: var(--font-serif); }
.quote cite { display: block; font-size: 14px; color: var(--c-muted); font-style: normal; margin-top: 6px; }

/* 關於 / 團隊 */
.about-intro { display: grid; grid-template-columns: 1.2fr 1fr; gap: 48px; align-items: start; }
.director { display: grid; grid-template-columns: 340px 1fr; gap: 40px; align-items: start; }
.director__photo img { border-radius: var(--radius); }
.director ul { padding-left: 1.1em; color: var(--c-muted); }
.timeline { list-style: none; padding: 0; margin: 24px 0 0; border-left: 3px solid var(--c-primary-light); }
.timeline li { padding: 0 0 20px 24px; position: relative; }
.timeline li::before { content: ""; position: absolute; left: -9px; top: 6px; width: 15px; height: 15px; border-radius: 50%; background: var(--c-primary); }
.timeline time { font-weight: 800; color: var(--c-primary); margin-right: 8px; }
.timeline h3 { font-size: 17px; margin: 0 0 4px; display: inline; }
.timeline p { margin: 4px 0 0; color: var(--c-muted); }
.team { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.member { background: #fff; box-shadow: var(--shadow); border-radius: var(--radius); overflow: hidden; }
.member img { width: 100%; aspect-ratio: 894 / 1034; object-fit: cover; }
.member__body { padding: 20px 22px; }
.member h3 { font-size: 19px; margin: 0; }
.member__role { color: var(--c-primary); font-weight: 700; font-size: 14px; }
.member__meta { font-size: 14px; color: var(--c-muted); margin: 8px 0; }
.member__bio { font-size: 15px; }

/* 聯絡 */
.contact { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; }
.contact dl { display: grid; grid-template-columns: 90px 1fr; gap: 10px 16px; margin: 0 0 24px; }
.contact dt { font-weight: 700; color: var(--c-primary-dark); }
.contact dd { margin: 0; }
.map { width: 100%; aspect-ratio: 4 / 3; border: 0; border-radius: var(--radius); background: var(--c-bg-soft); }
.line-box { display: flex; gap: 20px; align-items: center; background: var(--c-bg-soft); padding: 22px; border-radius: var(--radius); }
.line-box img { width: 120px; flex-shrink: 0; }

/* 分頁 */
.pager { display: flex; justify-content: center; gap: 8px; margin-top: 40px; list-style: none; padding: 0; }
.pager a, .pager span { display: inline-block; min-width: 42px; padding: 8px 12px; text-align: center; border: 1px solid var(--c-line); border-radius: var(--radius); }
.pager [aria-current] { background: var(--c-primary); color: #fff; border-color: var(--c-primary); }

/* ---------- 頁尾 ---------- */
.site-footer { background: #fff; border-top: 1px solid var(--c-line); font-size: 15px; }
.footer__grid { display: grid; grid-template-columns: 1.3fr 1.3fr 1fr 1.3fr; gap: 40px; padding-top: 56px; padding-bottom: 40px; }
.footer__brand img { width: 170px; margin-bottom: 14px; }
.footer__brand p { color: var(--c-muted); font-size: 14px; }
.footer__social { list-style: none; padding: 0; margin: 0; font-size: 14px; }
.footer__title { font-size: 17px; margin-bottom: 14px; }
.footer__nap { font-style: normal; color: var(--c-muted); line-height: 1.9; }
.footer__nap strong { color: var(--c-text); }
.footer__map { display: inline-block; margin-top: 8px; font-weight: 600; }
.footer__links { list-style: none; padding: 0; margin: 0; }
.footer__links a { color: var(--c-muted); line-height: 2; }
.footer__links--2col { columns: 2; column-gap: 12px; }
.footer__bottom { border-top: 1px solid var(--c-line); font-size: 13px; color: var(--c-muted); }
.footer__bottom-inner { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; padding-top: 14px; padding-bottom: 14px; }
.footer__bottom p { margin: 0; }
.footer__bottom a { color: var(--c-muted); margin-left: 20px; }

/* 浮動聯絡鈕 */
.float-cta { position: fixed; right: 18px; bottom: 18px; display: flex; flex-direction: column; gap: 10px; z-index: 90; }
.float-cta__btn { width: 54px; height: 54px; border-radius: 50%; display: flex; align-items: center; justify-content: center; color: #fff; box-shadow: 0 4px 14px rgba(0,0,0,.25); }
.float-cta__btn svg { width: 30px; height: 30px; }
.float-cta__line { background: var(--c-line-green); }
.float-cta__tel { background: var(--c-primary); }
.float-cta__btn:hover { color: #fff; transform: scale(1.06); }

/* ---------- 響應式 ---------- */
@media (max-width: 1024px) {
    .cards { grid-template-columns: repeat(2, 1fr); }
    .feature { grid-template-columns: 1fr; }
    .clients { grid-template-columns: repeat(4, 1fr); }
    .layout { grid-template-columns: minmax(0, 1fr); }
    .sidebar { position: static; }
    .steps { grid-template-columns: repeat(2, 1fr); }
    .services, .team { grid-template-columns: repeat(2, 1fr); }
    .footer__grid { grid-template-columns: 1fr 1fr; }
    .country-grid { grid-template-columns: repeat(3, 1fr); }
    .director { grid-template-columns: 260px 1fr; }
}

@media (max-width: 860px) {
    .header__contact { display: none; }
    .nav-toggle { display: block; width: 44px; height: 44px; border: 1px solid var(--c-line); background: #fff; border-radius: var(--radius); position: relative; cursor: pointer; }
    .nav-toggle__bar, .nav-toggle__bar::before, .nav-toggle__bar::after { position: absolute; left: 11px; width: 20px; height: 2px; background: var(--c-dark); content: ""; transition: .2s; }
    .nav-toggle__bar { top: 21px; }
    .nav-toggle__bar::before { left: 0; top: -6px; }
    .nav-toggle__bar::after { left: 0; top: 6px; }
    .nav-toggle[aria-expanded="true"] .nav-toggle__bar { background: transparent; }
    .nav-toggle[aria-expanded="true"] .nav-toggle__bar::before { top: 0; transform: rotate(45deg); }
    .nav-toggle[aria-expanded="true"] .nav-toggle__bar::after { top: 0; transform: rotate(-45deg); }
    .site-nav { display: none; position: static; }
    .site-nav.is-open { display: block; }
    .site-nav__inner { flex-direction: column; align-items: stretch; padding: 0; }
    .menu { flex-direction: column; }
    .menu > li { border-bottom: 1px solid var(--c-line); }
    .menu > li > a { padding: 14px 20px; }
    .menu > li > a[aria-current] { box-shadow: inset 4px 0 0 var(--c-primary); }
    .sub-toggle { display: block; position: absolute; right: 8px; top: 6px; width: 40px; height: 40px; border: 0; background: none; cursor: pointer; }
    .sub-toggle::after { content: "+"; font-size: 22px; color: var(--c-primary); }
    .sub-toggle[aria-expanded="true"]::after { content: "−"; }
    .has-sub:hover .submenu, .has-sub:focus-within .submenu { display: none; }
    .has-sub.is-open .submenu { display: block; position: static; box-shadow: none; border: 0; min-width: 0; padding: 0 20px 14px; }
    .menu__reviews { padding: 14px 20px; }
    .section { padding: 56px 0; }
    .hero { min-height: 440px; }
    .contact, .about-intro, .director { grid-template-columns: 1fr; }
}

@media (max-width: 600px) {
    .topbar__hours { display: none; }
    .topbar__inner { justify-content: flex-end; }
    .logo img { width: 140px; }
    .cards, .services, .team { grid-template-columns: 1fr; }
    .feature__card { grid-template-columns: 1fr; }
    .feature__card img { max-height: 220px; }
    .stats__num { font-size: 32px; }
    .stats__item { min-height: 140px; padding: 20px 16px; }
    .clients { grid-template-columns: repeat(3, 1fr); gap: 10px; }
    .steps { grid-template-columns: 1fr; }
    .footer__grid { grid-template-columns: 1fr; gap: 28px; }
    .country-grid { grid-template-columns: repeat(2, 1fr); }
    .spec th { width: auto; white-space: normal; }
    .spec, .spec tbody, .spec tr, .spec th, .spec td { display: block; }
    .spec tr { margin-bottom: 12px; }
    .post-nav { grid-template-columns: 1fr; }
    .quote { flex-direction: column; text-align: center; }
    .cta__btns .btn { flex: 1 1 100%; }
    .float-cta__btn { width: 50px; height: 50px; }
}

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

@media print {
    .site-header, .site-footer, .float-cta, .cta, .sidebar { display: none; }
}

/* ---------- 服務獨立頁 /services/{slug}（2026-10-09） ---------- */
.svc-intro { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 28px; align-items: start; margin-bottom: 8px; }
.svc-intro .hub-lead { margin: 0; }
.svc-intro__img img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: var(--radius); box-shadow: var(--shadow); }
.svc-steps { list-style: none; counter-reset: svc; padding: 0; margin: 0 0 8px; }
.svc-steps li { counter-increment: svc; position: relative; padding: 0 0 22px 60px; }
.svc-steps li::before { content: counter(svc); position: absolute; left: 0; top: 0; width: 40px; height: 40px; border-radius: 50%; background: var(--c-primary); color: #fff; font-weight: 800; display: flex; align-items: center; justify-content: center; }
.svc-steps li:not(:last-child)::after { content: ""; position: absolute; left: 19px; top: 44px; bottom: 4px; width: 2px; background: var(--c-primary-light); }
.svc-steps h3 { font-size: 18px; margin: 7px 0 4px; }
.svc-steps p { margin: 0; color: var(--c-muted); }
.svc-related { padding-left: 1.2em; }
.svc-related li { padding: 3px 0; }
.submenu--list { min-width: 220px; }
.submenu--list ul { columns: 1; }
@media (max-width: 760px) {
    .svc-intro { grid-template-columns: 1fr; }
    .svc-intro__img { order: -1; }
}
.svc-page .prose h2, .svc-page .prose h3 { scroll-margin-top: 90px; }

/* ---------- 顧問頁：所長介紹、諮詢方式（2026-10-09） ---------- */
.advisor { display: grid; grid-template-columns: 200px minmax(0, 1fr); gap: 28px; background: #fff; border: 1px solid var(--c-line); border-top: 4px solid var(--c-primary); border-radius: var(--radius); box-shadow: var(--shadow); padding: 28px; margin: 8px 0 32px; }
.advisor__photo { position: sticky; top: 90px; align-self: start; }
.advisor__photo img { width: 100%; aspect-ratio: 1; object-fit: cover; border-radius: var(--radius); }
.advisor__eyebrow { color: var(--c-primary); font-weight: 700; font-size: 14px; margin: 0 0 4px; letter-spacing: .05em; }
.prose .advisor h2 { margin: 0 0 10px; padding: 0; border: 0; font-size: 22px; }
.advisor__name { display: flex; flex-wrap: wrap; gap: 4px 14px; align-items: baseline; margin: 0 0 12px; color: var(--c-muted); font-size: 15px; }
.advisor__name strong { color: var(--c-dark); font-size: 19px; }
.advisor__points { margin: 0 0 16px; padding-left: 1.2em; }
.advisor__points li { padding: 2px 0; }
.advisor__motto { margin: 0 0 12px; padding: 12px 16px; background: var(--c-primary-light); border-left: 4px solid var(--c-accent); border-radius: 0 var(--radius) var(--radius) 0; font-weight: 700; color: var(--c-primary-dark); }
.advisor__motto cite { display: block; margin-top: 4px; font-style: normal; font-weight: 400; font-size: 14px; color: var(--c-muted); }
.advisor__more { font-weight: 600; }
.plans { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 16px; margin: 16px 0 24px; }
.plan { background: #fff; border: 1px solid var(--c-line); border-top: 4px solid var(--c-primary); border-radius: var(--radius); padding: 18px 18px 14px; }
.plan:nth-child(2) { border-top-color: var(--c-accent); }
.plan:nth-child(3) { border-top-color: var(--c-primary-dark); }
.prose .plan h3 { margin: 0 0 6px; font-size: 19px; color: var(--c-primary-dark); }
.plan__fit { font-size: 14px; color: var(--c-muted); margin: 0 0 10px; padding-bottom: 10px; border-bottom: 1px dashed var(--c-line); }
.plan ul { margin: 0; padding-left: 1.1em; font-size: 15px; }
.plan li { padding: 3px 0; }
.consult-box { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 24px; background: var(--c-bg-soft); border-radius: var(--radius); padding: 22px 24px; margin-bottom: 8px; }
.prose .consult-box h3 { margin: 0 0 10px; font-size: 18px; }
.consult-box ul { margin: 0; padding-left: 1.1em; }
.consult-box__contact { display: flex; flex-direction: column; gap: 10px; }
.consult-box__contact .btn { width: 100%; }
.consult-box__contact p { margin: 4px 0 0; font-size: 14px; color: var(--c-muted); }
@media (max-width: 900px) {
    .plans { grid-template-columns: 1fr; }
    .consult-box { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
    .advisor { grid-template-columns: 1fr; padding: 20px; }
    .advisor__photo { max-width: 180px; position: static; }
}

/* ---------- 首頁「最新動態」：文字＋Facebook 粉絲專頁（2026-10-09，對應舊站版面） ---------- */
.news-fb { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 520px); gap: 48px; align-items: center; }
.news-fb__text h3 { font-size: 24px; color: var(--c-muted); margin: 0 0 18px; }
.news-fb__text p { color: var(--c-muted); }
.news-fb__text .btn { margin-top: 10px; }
.news-fb__list { list-style: none; padding: 0; margin: 28px 0 10px; border-top: 1px solid var(--c-line); }
.news-fb__list li { display: flex; gap: 14px; padding: 12px 0; border-bottom: 1px solid var(--c-line); }
.news-fb__list time { flex: none; color: var(--c-muted); font-size: 14px; padding-top: 2px; }
.news-fb__more { font-weight: 600; font-size: 15px; }
.news-fb__embed { position: relative; background: #fff; box-shadow: var(--shadow); border-radius: var(--radius); padding: 10px; min-height: 260px; display: flex; justify-content: center; align-items: flex-start; }
.news-fb__embed iframe { display: block; max-width: 100%; }
.news-fb__fallback { position: absolute; inset: 10px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; text-align: center; color: var(--c-text); background: var(--c-bg-soft); border-radius: var(--radius); padding: 24px; }
.news-fb__fallback img { width: 160px; height: auto; }
.news-fb__fallback span { color: var(--c-primary); font-weight: 600; }
.news-fb__embed.is-loaded .news-fb__fallback { display: none; }
@media (max-width: 900px) {
    .news-fb { grid-template-columns: 1fr; gap: 28px; }
}

/* ---------- 右下角 LINE 按鈕：電腦版滑鼠移過去顯示 QR Code（2026-10-09，對應舊站功能） ---------- */
.float-cta__line-wrap { position: relative; }
.float-cta__qr { display: none; }
@media (hover: hover) and (min-width: 768px) {
    .float-cta__qr { display: flex; flex-direction: column; align-items: center; gap: 6px; width: max-content; position: absolute; right: calc(100% + 14px); top: 50%; transform: translate(8px, -50%); background: #fff; padding: 12px 12px 10px; border-radius: var(--radius); box-shadow: 0 6px 24px rgba(0,0,0,.18); opacity: 0; visibility: hidden; pointer-events: none; transition: opacity .2s, transform .2s, visibility .2s; }
    .float-cta__qr::after { content: ""; position: absolute; left: 100%; top: 50%; transform: translateY(-50%); border: 7px solid transparent; border-left-color: #fff; }
    .float-cta__qr img { width: 140px; height: 140px; max-width: none; flex: none; image-rendering: pixelated; }
    .float-cta__qr span { font-size: 13px; color: var(--c-text); white-space: nowrap; }
    .float-cta__line-wrap:hover .float-cta__qr, .float-cta__line-wrap:focus-within .float-cta__qr { opacity: 1; visibility: visible; transform: translate(0, -50%); }
}
