/* 拓趨數位官網 prototype 共用樣式（首頁、部落格列表共用） */
/* ===== 色彩與字型變數（對應 Figma 的灰階線框色） ===== */
:root {
  --bg-light: #f0f0f0;
  --bg-dark: #1c1c1c;
  --white: #fff;
  --text: #1e1e1e;
  --text-strong: #171717;
  --text-muted: #737373;
  --text-label: #747474;
  --border: #dedede;
  --btn-dark: #2c2c2c;    --font-zh: "Noto Sans TC", "PingFang TC", sans-serif;
  --font-en: "Urbanist", "Noto Sans TC", sans-serif;
  --gutter: clamp(16px, 4.6vw, 80px);
  /* 內頁（部落格、文章、服務流程）內容最寬 1400px：左右留白取「一般留白」與「(螢幕寬 − 1400) ÷ 2」較大者 */
  --inner-pad: max(var(--gutter), calc((100% - 1400px) / 2));
}
* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body { font-family: var(--font-zh); color: var(--text); background: var(--white); -webkit-font-smoothing: antialiased; }
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; border: 0; background: none; color: inherit; }
.en { font-family: var(--font-en); }
.label { font-family: var(--font-en); font-weight: 500; font-size: 16px; line-height: 1.5; color: var(--text-label); letter-spacing: .5px; }

/* ===== 按鈕 ===== */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 48px; padding: 0 24px; border-radius: 10px; font-size: 16px; font-weight: 500; white-space: nowrap; transition: background .15s, opacity .15s; }
.btn-light { background: var(--white); color: var(--text); }
.btn-light:hover { background: #e6e6e6; }
.btn-dark { background: var(--btn-dark); color: #fff; border: 1px solid var(--btn-dark); }
.btn-dark:hover { opacity: .85; }
.btn-outline { border: 1px solid #555; color: #aaa; padding: 0 32px; }
.btn-outline:hover { border-color: #999; color: #ddd; }
/* 第二屏「立即聊聊」：沒選選項前是暗的不能按，選了就亮起（灰階，不帶品牌色以免搶焦點） */
.btn-goal img { opacity: .5; }
.btn-goal:disabled { cursor: not-allowed; }
.btn-goal:disabled:hover { border-color: #555; color: #aaa; }
.btn-goal:not(:disabled) { background: #fff; border-color: #fff; color: #1c1c1c; } /* 亮起＝白底黑字 */
.btn-goal:not(:disabled) img { opacity: 1; filter: brightness(0); } /* 白色 icon 轉成黑色 */
.btn-goal:not(:disabled):hover { background: #e6e6e6; border-color: #e6e6e6; }
.btn img { width: 20px; height: 20px; }

/* ===== Header ===== */
/* Header 固定在畫面上方：logo 一直在，右側選單往下讀時收起、往回捲時出現 */
.header { position: fixed; top: 32px; left: 50px; right: 50px; display: flex; align-items: center; justify-content: space-between; z-index: 40; pointer-events: none; }
.header > * { pointer-events: auto; }
.header .logo { width: 200px; height: 36px; transition: filter .25s; }
.header.on-dark .logo { filter: brightness(0) invert(1); } /* 深色區塊上 logo 改白色 */
.header-right { position: relative; display: flex; align-items: center; transition: transform .3s ease, opacity .3s ease; }
.header.nav-hidden .header-right { transform: translateY(-120px); opacity: 0; pointer-events: none; }
/* 中小網常駐的「聯絡我們」按鈕（桌機選單裡已有，這顆只在 1100px 以下出現） */
.header-contact { display: none; }
.nav { display: flex; gap: 12px; align-items: center; }
.dropdown { position: relative; }
.dropdown .btn img { transition: transform .2s; }
.dropdown.open .btn img { transform: rotate(180deg); }
.dropdown-menu { text-align: left; position: absolute; top: 60px; right: 0; width: 408px; background: #fff; border: 1px solid #eee; border-radius: 18px; padding: 4px 16px; box-shadow: 0 12px 40px -8px rgba(28,28,28,.08); opacity: 0; visibility: hidden; transform: translateY(-6px); transition: .18s; }
.dropdown.open .dropdown-menu { opacity: 1; visibility: visible; transform: none; }
.product { display: flex; align-items: center; gap: 16px; height: 88px; border-bottom: 1px solid #eee; }
.product:last-child { border-bottom: 0; }
.product:hover .product-name { text-decoration: underline; }
.product > img:first-child { width: 64px; height: 64px; border-radius: 10px; object-fit: cover; }
.product-info { flex: 1; min-width: 0; }
.product-name { font-family: var(--font-en); font-weight: 600; font-size: 18px; line-height: 24px; }
.product-desc { font-size: 14px; line-height: 22px; color: #777; }
.product .go { width: 20px; height: 20px; transform: rotate(-90deg); }
/* 漢堡選單按鈕（三條線，展開時變成 ×） */
.menu-toggle { display: none; width: 48px; padding: 0; flex-direction: column; gap: 5px; }
.menu-toggle span { width: 20px; height: 2px; border-radius: 1px; background: var(--text); transition: transform .2s, opacity .2s; }
.menu-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.menu-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.menu-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ===== Hero ===== */
.hero { position: relative; min-height: 950px; height: 100vh; max-height: 1100px; background: var(--bg-light); display: flex; align-items: center; justify-content: center; text-align: center; padding: 140px var(--gutter) 80px; }
.hero-eyebrow { font-family: var(--font-en); font-weight: 500; font-size: 20px; letter-spacing: .3px; }
.hero-eyebrow b { font-weight: 700; letter-spacing: 1px; }
.hero h1 { margin-top: 20px; font-weight: 500; font-size: clamp(36px, 5vw, 86px); line-height: 1.28; color: #111; letter-spacing: .3px; }
.hero-tags { margin-top: 24px; display: flex; gap: 10px; align-items: center; justify-content: center; font-size: clamp(18px, 1.4vw, 24px); flex-wrap: wrap; }
.hero-tags img { width: 18px; height: 18px; }

/* 右下角漂浮的聊天 CTA（捲動時固定在畫面上） */
.chat-cta { position: fixed; right: 40px; bottom: 40px; z-index: 30; width: 240px; background: #fff; border-radius: 20px; padding: 15px; display: flex; flex-direction: column; align-items: center; gap: 23px; box-shadow: 0 8px 30px rgba(0,0,0,.08); overflow: hidden; transition: width .25s ease, padding .25s ease, gap .25s ease, border-radius .25s ease, background-color .25s, box-shadow .25s, opacity .2s; }
.chat-cta p { font-size: 16px; line-height: 27px; text-align: center; white-space: nowrap; max-height: 60px; transition: max-height .25s ease, opacity .2s; }
.chat-cta strong { font-size: 24px; }
.chat-cta .btn { width: 100%; transition: height .25s ease, border-radius .25s ease; }
/* 離開首屏後：縮成 60x60 黑色按鈕（只留 32px 聊天 icon，無白底無 padding）；hover 只有按鈕效果，點擊直接開聊天室 */
.chat-cta.mini { width: 60px; padding: 0; gap: 0; border-radius: 30px; background: transparent; box-shadow: 0 8px 24px rgba(0,0,0,.18); }
.chat-cta.mini p { max-height: 0; opacity: 0; overflow: hidden; pointer-events: none; } /* 收起的文字不可擋住按鈕點擊 */
.chat-cta.mini .btn { height: 60px; padding: 0; border-radius: 30px; }
.chat-cta.mini .btn img { width: 32px; height: 32px; transition: transform .2s; }
.chat-cta.mini .btn span { display: none; }
.chat-cta.mini .btn:hover { opacity: 1; background: #444; border-color: #444; }
.chat-cta.mini .btn:hover img { transform: scale(1.1); }
.chat-cta.hidden { opacity: 0; pointer-events: none; }

/* ===== 聊天視窗（灰階） ===== */
.chat-panel { position: fixed; right: 40px; bottom: 40px; z-index: 50; width: 400px; height: min(640px, calc(100vh - 80px)); display: flex; flex-direction: column; background: #f4f4f4; border: 1px solid #d6d6d6; border-radius: 20px; overflow: hidden; box-shadow: 0 20px 60px rgba(0,0,0,.2); opacity: 0; visibility: hidden; transform: translateY(16px) scale(.98); transform-origin: bottom right; transition: .22s ease; }
.chat-panel.open { opacity: 1; visibility: visible; transform: none; }
.chat-top { display: flex; align-items: center; justify-content: space-between; padding: 22px 24px; background: #2c2c2c; color: #fff; }
.chat-top h3 { font-size: 18px; font-weight: 700; }
.chat-top button { width: 32px; height: 32px; font-size: 22px; line-height: 1; border-radius: 8px; }
.chat-top button:hover { background: rgba(255,255,255,.12); }
.chat-log { flex: 1; overflow-y: auto; padding: 20px 16px; display: flex; flex-direction: column; gap: 16px; }
.cmsg { max-width: 82%; padding: 12px 16px; border-radius: 16px; font-size: 15px; line-height: 1.7; word-break: break-word; }
.cmsg.me { align-self: flex-end; background: #2c2c2c; color: #fff; }
.cmsg-ai { align-self: flex-start; max-width: 82%; }
/* 小幫手常問問題膠囊 */
.chat-chips { display: flex; flex-wrap: wrap; gap: 8px; margin-top: -4px; }
.chat-chips button { padding: 8px 14px; border-radius: 999px; background: #fff; border: 1px solid #d6d6d6; font-size: 13px; color: #333; transition: border-color .15s, background .15s; }
.chat-chips button:hover { border-color: #1c1c1c; }
.chat-chips button:active { background: #ececec; }
.cmsg-ai .cmsg { max-width: none; background: #fff; border: 1px solid #dedede; color: #1e1e1e; }
.cmsg a { text-decoration: underline; }
.rate { display: flex; gap: 8px; margin: 6px 0 0 8px; }
.rate button { font-size: 16px; padding: 2px 6px; border-radius: 6px; filter: grayscale(1); opacity: .55; }
.rate button:hover { opacity: .9; }
.rate button[aria-pressed="true"] { opacity: 1; background: #e2e2e2; }
.typing { display: flex; gap: 4px; padding: 16px; }
.typing i { width: 6px; height: 6px; border-radius: 3px; background: #999; animation: blink 1s infinite; }
.typing i:nth-child(2) { animation-delay: .15s; } .typing i:nth-child(3) { animation-delay: .3s; }
@keyframes blink { 0%, 100% { opacity: .3; } 50% { opacity: 1; } }
.chat-note { padding: 8px 16px; font-size: 12px; color: #777; text-align: center; background: #f4f4f4; }
.chat-form { display: flex; gap: 12px; align-items: flex-end; padding: 12px 16px; background: #fff; border-top: 1px solid #e2e2e2; }
/* 輸入框：一行 52px 高，打超過一行自動長高，最多 5 行，再多就出現捲軸 */
.chat-form textarea { flex: 1; min-width: 0; height: 52px; padding: 14px 16px; font: inherit; font-size: 15px; line-height: 22px; border: 1px solid #dedede; border-radius: 12px; outline: none; resize: none; overflow-y: hidden; display: block; }
.chat-form textarea:focus { border-color: #888; }
.cmsg.me { white-space: pre-wrap; }
.chat-form button { width: 52px; height: 52px; flex: none; border-radius: 26px; background: #2c2c2c; color: #fff; font-size: 22px; }
.chat-form button:disabled { background: #bdbdbd; cursor: default; }

/* ===== 目標選擇（深色） ===== */
.goals { background: var(--bg-dark); padding: 160px var(--gutter); display: flex; flex-direction: column; align-items: center; gap: 100px; text-align: center; }
.goals .eyebrow { font-family: var(--font-en); font-weight: 500; font-size: 14px; letter-spacing: 2px; color: #888; }
.goals h2 { margin-top: 16px; font-weight: 500; font-size: clamp(30px, 3.3vw, 56px); line-height: 1.3; color: #fff; }
.chips { display: flex; flex-wrap: wrap; justify-content: center; gap: 36px 32px; max-width: 1154px; }
.chip { padding: 14px 28px; border-radius: 100px; background: #2a2a2a; border: 1px solid #444; color: #d4d4d4; font-size: 16px; line-height: 1.5; transition: .15s; }
.chip.alt { background: #323232; border-color: #555; }
.chip:hover { border-color: #888; }
.chip[aria-pressed="true"] { background: #fff; color: #1c1c1c; border-color: #fff; }
.goals-hint { color: #888; font-size: 14px; min-height: 21px; margin-top: -70px; }

/* ===== 服務（Our Mission） ===== */
.service-wrap { background: var(--bg-light); padding: 20px; }
.service { background: #fafaf8; border-radius: 24px; padding: 64px; max-width: 1670px; margin: 0 auto; }
.section-head h2 { margin-top: 20px; font-weight: 500; font-size: clamp(30px, 2.8vw, 47px); line-height: 1.3; color: var(--text-strong); }
.section-head .sub { margin-top: 20px; font-size: 18px; line-height: 1.5; color: var(--text-muted); }
.cards { margin-top: 60px; display: grid; grid-template-columns: repeat(4, minmax(0, 366px)); gap: 26px; }
.card-visual { position: relative; height: 425px; border-radius: 21px; overflow: hidden; padding: 25px 24px; }
.card-visual.dark { background: #101111; }
.card-visual.light { background: #ececeb; }
.card-visual .tag { font-family: var(--font-en); font-weight: 500; font-size: 20px; line-height: 1.5; }
.dark .tag { color: #9c9e9d; }
.light .tag { color: #858584; }
.card-text { padding: 29px 15px 0; }
.card-text h3 { font-weight: 700; font-size: 23px; line-height: 1.4; color: var(--text-strong); }
.card-text p { margin-top: 12px; font-size: 16px; line-height: 1.7; color: #727272; }

/* 卡片內的迷你介面示意 */
.mock { position: absolute; left: 50%; transform: translateX(-50%); width: calc(100% - 48px); max-width: 318px; overflow: hidden; }
/* AI Agent */
.mock-agent { top: 90px; height: 277px; background: #202222; border: 1px solid #363838; border-radius: 14px; padding: 16px 17px; color: #f5f5f3; }
.mock-agent .title { font-size: 13px; font-weight: 500; }
.mock-agent hr { border: 0; height: 1px; background: #353535; margin: 14px -8px 20px; }
.mock-agent .task { margin-left: 35px; background: #363938; border-radius: 9px; padding: 15px 12px; font-size: 11px; color: #f3f3f1; }
.mock-agent .done { margin-top: 16px; font-size: 12px; font-weight: 500; }
.step { margin-top: 5px; display: flex; align-items: center; gap: 12px; height: 24px; padding: 0 9px; background: #292c2b; border-radius: 5px; font-size: 10px; color: #c2c7c4; }
.mock-agent .done + .step { margin-top: 12px; }
.step::before { content: ""; width: 6px; height: 6px; border-radius: 3px; background: #c3cdc6; flex: none; }
/* 系統自動化 */
.mock-flow { top: 101px; height: 270px; background: #fff; border: 1px solid #dfdfdd; border-radius: 13px; padding: 16px; }
.mock-flow .title { font-size: 13px; font-weight: 500; color: #262626; }
.mock-flow .meta { font-size: 10px; color: #8a8a88; margin: 4px 0 16px; }
.node { position: relative; display: flex; gap: 12px; align-items: flex-start; height: 47px; padding: 5px 10px; background: #f6f6f4; border: 1px solid #e7e7e3; border-radius: 8px; }
.node + .node { margin-top: 16px; }
.node + .node::before { content: ""; position: absolute; left: 24px; top: -17px; width: 1px; height: 17px; background: #c6c8c5; }
.node i { width: 9px; height: 9px; border-radius: 5px; background: #59685e; margin-top: 11px; flex: none; }
.node b { display: block; font-size: 11px; font-weight: 500; color: #333833; line-height: 1.5; }
.node span { display: block; font-size: 9px; color: #91938f; line-height: 1.5; margin-top: 2px; }
/* AI 產品 */
.mock-product { top: 76px; height: 307px; max-width: 300px; background: #f9f9f6; border: 1px solid #4a4d49; border-radius: 15px; }
.mock-product .bar { display: flex; justify-content: space-between; align-items: center; height: 42px; padding: 0 8px 0 15px; background: #eceee8; font-size: 12px; font-weight: 700; color: #252b25; }
.mock-product .bar span { background: #dddfd9; border-radius: 7px; padding: 5px 6px; font-size: 11px; font-weight: 500; color: #555b53; }
.mock-product .body { padding: 20px 16px; }
.mock-product h4 { font-size: 18px; font-weight: 500; color: #212720; padding-left: 2px; }
.mock-product .hint { font-size: 10px; color: #8a8e85; margin: 4px 0 14px 2px; }
.mock-product .input { position: relative; height: 73px; background: #fff; border: 1px solid #d9ddd3; border-radius: 9px; padding: 12px; font-size: 10px; color: #9ba093; }
.mock-product .input span { position: absolute; right: 12px; bottom: 10px; background: #292f26; color: #f0f2e9; font-size: 11px; font-weight: 500; padding: 8px 14px; border-radius: 7px; }
.mock-product .ws { font-family: var(--font-en); font-size: 12px; font-weight: 500; color: #94998e; margin: 20px 0 6px 2px; }
.mock-product .tiles { display: flex; gap: 12px; }
.mock-product .tiles span { flex: 1; text-align: center; padding: 14px 7px; border-radius: 8px; background: #e7eadf; font-size: 11px; font-weight: 500; color: #5b6352; }
.mock-product .tiles span + span { background: #ecede7; }
/* AI Chatbot */
.mock-chat { top: 101px; height: 270px; background: #fff; border: 1px solid #dfdfdd; border-radius: 13px; padding: 16px; }
.chat-box { height: 100%; background: #f7f8f6; border: 1px solid #e6e7e2; border-radius: 12px; padding: 12px; display: flex; flex-direction: column; gap: 10px; color: #353b30; }
.chat-head { display: flex; justify-content: space-between; align-items: center; font-size: 12px; font-weight: 500; }
.chat-head .who { display: flex; gap: 8px; align-items: center; }
.avatar { width: 24px; height: 24px; border-radius: 12px; background: #eef0e9; display: grid; place-items: center; font-size: 10px; font-weight: 500; color: #77806e; flex: none; }
.avatar img { width: 14px; height: 14px; }
.avatar.ai { background: #30372e; color: #fff; }
.chat-head .status { display: flex; gap: 6px; align-items: center; font-size: 10px; font-weight: 400; color: #90938c; }
.chat-head .status img { width: 8px; height: 8px; }
.msg { display: flex; gap: 8px; align-items: flex-end; }
.msg.user { justify-content: flex-end; }
.bubble { width: 170px; padding: 10px 12px; font-size: 11px; line-height: 1.5; border-radius: 12px; }
.msg.user .bubble { background: #fff; border: 1px solid #e6e7e2; border-bottom-left-radius: 2px; }
.msg.ai .bubble { background: #eef0e9; border-bottom-right-radius: 2px; }
.quick { display: flex; gap: 8px; justify-content: center; }
.quick span { width: 88px; text-align: center; padding: 8px 0; background: #fff; border: 1px solid #e6e7e2; border-radius: 10px; font-size: 10px; font-weight: 500; }

/* ===== 服務流程 ===== */
/* 桌機：左側說明黏住並等於螢幕高度，右側七階段持續捲動；右側捲到底，左側跟著一起滑走 */
.process { padding: 0 var(--gutter) 100px; display: flex; align-items: flex-start; gap: 56px; }
.process-intro { position: sticky; top: 0; height: 100vh; min-height: fit-content; width: 344px; flex: none; padding: 120px 48px 48px 0; display: flex; flex-direction: column; justify-content: flex-start; gap: 40px; }   /* 驗收原則緊接在標題下方（向上對齊） */
/* 左右之間的分隔線：上下留白，和左側內容的頭尾對齊 */
.process-intro::after { content: ""; position: absolute; right: 0; top: 120px; bottom: 48px; width: 1px; background: var(--border); }
.process-intro .sub { line-height: 2; }
.sub-lines span { display: block; } /* 桌機、平板一句一行 */
/* 驗收原則：三點各自一張卡片 */
.principles h4 { font-size: 18px; font-weight: 700; }
.principles ul { margin-top: 16px; list-style: none; display: grid; gap: 10px; }
.principles li { display: flex; gap: 12px; align-items: baseline; padding: 18px 20px; background: var(--bg-light); border-radius: 14px; font-size: 16px; line-height: 1.6; color: #444; }
.principles li span { flex: none; font-family: var(--font-en); font-size: 13px; color: #999; }
/* 三個服務的 Tab */
.ptabs { display: flex; gap: 4px; padding: 5px; background: var(--bg-light); border-radius: 14px; width: fit-content; max-width: 100%; overflow-x: auto; scrollbar-width: none; scroll-margin-top: 110px; }
.ptabs::-webkit-scrollbar { display: none; }
.ptab { flex: none; height: 44px; padding: 0 20px; border-radius: 10px; font-size: 16px; font-weight: 500; color: #6a6a6a; white-space: nowrap; transition: background .15s, color .15s; }
.ptab:hover { color: var(--text); }
.ptab[aria-selected="true"] { background: #fff; color: var(--text); box-shadow: 0 1px 4px rgba(0,0,0,.08); }

/* 七個步驟（純文字）：整列可點，前往服務流程內頁對應步驟 */
.process-main { flex: 1; min-width: 0; padding-top: 120px; }   /* 120px＝左側分隔線的起點，Tab 頂端與它對齊 */
.ptab-lead { margin-top: 24px; font-size: 18px; line-height: 2; color: var(--text-muted); }
.process-main .steps { margin-top: 16px; }
.steps { flex: 1; min-width: 0; list-style: none; }
.steps li { border-bottom: 1px solid var(--border); }
.steps li:last-child { border-bottom: 0; }
.step-link { display: flex; gap: 20px; padding: 32px 0; }
.steps li:last-child .step-link { padding-bottom: 48px; }   /* 48px＝左側分隔線底端的留白：最後一步文字底端與分隔線底端切齊，一起滑走 */
.steps .num { font-family: var(--font-en); font-size: 20px; line-height: 38px; color: #777; width: 28px; flex: none; }
.step-link > div { flex: 1; min-width: 0; }
.steps h3 { font-size: 32px; font-weight: 700; color: #303030; }
.steps p { margin-top: 16px; font-size: 18px; line-height: 28px; color: #626262; }
.step-link .go { width: 24px; height: 24px; flex: none; margin-top: 8px; transform: rotate(-90deg); opacity: 0; transition: opacity .2s, transform .2s; }
.step-link:hover h3 { text-decoration: underline; text-underline-offset: 6px; text-decoration-thickness: 2px; }
.step-link:hover .go { opacity: 1; transform: rotate(-90deg) translateY(4px); }

/* ===== 內頁右側 sticky 側欄（文章頁、服務流程頁共用）：推薦閱讀＋LET’S TALK ===== */
.side { position: sticky; top: 120px; display: flex; flex-direction: column; gap: 24px; }
.side h2 { font-size: 18px; font-weight: 700; }
.related { padding: 24px; border: 1px solid var(--border); border-radius: 20px; }
.related ul { list-style: none; margin-top: 16px; display: grid; gap: 4px; }
.related a { display: grid; grid-template-columns: 96px minmax(0, 1fr); gap: 14px; align-items: center; padding: 8px; margin: 0 -8px; border-radius: 12px; transition: background .15s; }
.related a:hover { background: var(--bg-light); }
.related img { width: 100%; aspect-ratio: 16 / 9; object-fit: cover; border-radius: 8px; }
.related b { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; font-size: 15px; line-height: 1.5; }
.related small { display: block; margin-top: 4px; font-family: var(--font-en); font-size: 13px; color: #999; }
.related .more { display: inline-flex; align-items: center; gap: 6px; margin-top: 12px; font-size: 15px; font-weight: 500; }
.related .more img { width: 16px; height: 16px; transform: rotate(-90deg); }
.side-cta { padding: 28px; background: var(--bg-dark); border-radius: 20px; color: #fff; scroll-margin-top: 120px; }
.side-cta .eyebrow { font-family: var(--font-en); font-size: 14px; letter-spacing: 1px; color: #888; }
.side-cta h2 { margin-top: 12px; font-size: 20px; line-height: 1.5; font-weight: 500; }
.side-cta p { margin-top: 8px; font-size: 15px; line-height: 1.7; color: #b5b5b5; }
.side-cta .actions { margin-top: 24px; display: grid; gap: 10px; }
.side-cta .btn { width: 100%; }
.btn-ghost { border: 1px solid #555; color: #fff; }
.btn-ghost:hover { border-color: #999; }
/* 有側欄的頁面：桌機時側欄已有「立即聊聊」，右下浮動按鈕不顯示 */
@media (min-width: 1101px) { .has-side .chat-cta { display: none; } }
@media (max-width: 1100px) { .side { position: static; display: grid; grid-template-columns: 1fr 1fr; align-items: start; } }
@media (max-width: 640px) { .side { grid-template-columns: 1fr; } }

/* ===== 資訊安全（首頁，服務流程與 Blog 之間） ===== */
.security { background: var(--bg-dark); padding: 120px var(--gutter); color: #fff; }
.sec-head .eyebrow { font-family: var(--font-en); font-weight: 500; font-size: 14px; letter-spacing: 2px; color: #888; }
.sec-head h2 { margin-top: 16px; font-weight: 500; font-size: clamp(30px, 3.3vw, 56px); line-height: 1.3; }
.sec-head .sub { margin-top: 20px; max-width: 760px; font-size: 18px; line-height: 1.8; color: #b5b5b5; }
.sec-cards { margin-top: 64px; list-style: none; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.sec-card { padding: 36px 32px; background: #262626; border: 1px solid #3a3a3a; border-radius: 20px; }
.sec-card .n { font-family: var(--font-en); font-size: 14px; color: #888; }
.sec-card h3 { margin-top: 20px; font-size: 24px; font-weight: 700; line-height: 1.45; }
.sec-tag { display: inline-block; margin-left: 8px; padding: 2px 10px; border: 1px solid #666; border-radius: 999px; font-size: 13px; font-weight: 500; color: #ccc; vertical-align: middle; }
.sec-card ul { margin-top: 20px; padding-left: 18px; display: grid; gap: 12px; font-size: 16px; line-height: 1.75; color: #b5b5b5; }

/* ===== Blog ===== */
.blog { background: var(--bg-light); padding: 100px var(--gutter); }
.blog-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; }
.blog-head h2 { font-size: clamp(32px, 3.3vw, 56px); }
.blog-head .sub { line-height: 1.8; }
.posts { margin-top: 60px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; }
.post { background: #fff; border: 1px solid var(--border); border-radius: 24px; overflow: hidden; display: flex; flex-direction: column; transition: transform .2s, box-shadow .2s; }
.post:hover { transform: translateY(-4px); box-shadow: 0 12px 30px rgba(0,0,0,.06); }
.post > img { width: 100%; aspect-ratio: 16 / 9; height: auto; object-fit: cover; } /* 各寬度都維持 16:9 */
.post-body { flex: 1; padding: 24px 32px 32px; display: flex; flex-direction: column; gap: 16px; }
.post-meta { display: flex; gap: 12px; align-items: center; font-family: var(--font-en); font-size: 14px; color: var(--text-label); }
.post-meta i { width: 4px; height: 4px; border-radius: 2px; background: var(--border); }
.post h3 { font-size: 28px; font-weight: 700; line-height: 1.4; }
.post p { flex: 1; font-size: 16px; line-height: 1.8; color: #727272; }
.read { display: inline-flex; gap: 8px; align-items: center; font-weight: 500; }
.read img { width: 20px; height: 20px; transform: rotate(-90deg); }

/* ===== 聯絡 CTA ===== */
.contact { background: var(--bg-dark); padding: 120px var(--gutter); }
.contact .eyebrow { font-family: var(--font-en); font-weight: 500; font-size: 16px; color: #b5b5b5; }
.contact .lead { margin-top: 32px; font-size: clamp(22px, 1.9vw, 32px); line-height: 1.8; color: #b5b5b5; }
.contact h2 { margin-top: 12px; font-weight: 500; font-size: clamp(32px, 3.3vw, 56px); line-height: 1.3; color: #fff; }
.contact .actions { margin-top: 40px; display: flex; gap: 16px; flex-wrap: wrap; }

/* 內頁的聯絡區與頁尾也一律最寬 1400px */
.inner .contact, .inner .footer { padding-left: var(--inner-pad); padding-right: var(--inner-pad); }

/* ===== Footer ===== */
.footer { background: var(--bg-light); padding: 64px var(--gutter) 32px; }
.footer-top { display: flex; justify-content: space-between; gap: 40px; }
.footer-brand { max-width: 540px; }
.footer-brand img { width: 201px; height: 36px; }
.footer-brand h4 { margin-top: 24px; font-size: 20px; font-weight: 700; line-height: 1.5; }
.footer-brand p { margin-top: 4px; color: var(--text-muted); line-height: 1.5; }
.footer-brand p a:hover { color: var(--text); text-decoration: underline; }
.footer-brand .hours { margin-top: 12px; }   /* 與上方地址電話同字級 */
.footer-nav { display: flex; align-items: flex-start; gap: 40px; padding-top: 6px; font-weight: 500; line-height: 1.5; flex-wrap: wrap; }
/* 產品介紹下方的四個產品子頁入口 */
.fn-sub { list-style: none; margin-top: 12px; display: grid; gap: 8px; }
.fn-title { cursor: default; }   /* 產品介紹沒有主頁：純標題，不可點、無底線 */
.fn-sub a { font-family: var(--font-en); font-size: 16px; font-weight: 400; color: var(--text-muted); white-space: nowrap; }
.fn-sub a:hover { color: var(--text); }
.footer-nav a:hover, .totop:hover { text-decoration: underline; }
.footer-bottom { margin-top: 50px; padding-top: 24px; border-top: 1px solid #d6d6d6; display: flex; justify-content: space-between; font-size: 14px; color: var(--text-muted); }
.totop { display: flex; gap: 8px; align-items: center; }
.totop img { width: 16px; height: 16px; }

/* ===== RWD ===== */
@media (max-width: 1500px) {
  .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 1100px) {
  .sec-cards { grid-template-columns: 1fr; max-width: 720px; }
  .process { flex-direction: column; align-items: stretch; padding-top: 100px; }
  .process-main { padding-top: 0; }
  /* 平板、手機：驗收原則放在服務流程文字右側（左右並排，不上下疊） */
  .process-intro::after { display: none; }
  .process-intro { position: static; height: auto; padding: 20px 0 0; width: auto; flex-direction: row; align-items: flex-start; gap: 24px; }
  .process-intro .section-head { flex: 1; min-width: 0; }
  .principles { flex: 1; max-width: 340px; min-width: 0; }
  .posts { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
  .footer-top { flex-direction: column; }
  /* 中小網：選單常駐，捲動時不往上收；「聯絡我們」常態顯示在漢堡選單左側 */
  .header.nav-hidden .header-right { transform: none; opacity: 1; pointer-events: auto; }
  .header-right { gap: 8px; }
  .header-contact { display: inline-flex; }
  .nav > a.btn-dark[href="contact.html"] { display: none; }   /* 選單外已有常駐按鈕，選單內不重複 */
  /* 1100px 以下：右側導覽收進漢堡選單 */
  .menu-toggle { display: inline-flex; }
  .nav { display: none; position: absolute; top: 60px; right: 0; flex-direction: column; align-items: stretch; background: #fff; padding: 12px; border-radius: 16px; box-shadow: 0 12px 40px -8px rgba(28,28,28,.15); width: min(320px, calc(100vw - 32px)); }
  .nav.open { display: flex; }
  .dropdown .btn { width: 100%; }
  .dropdown-menu { position: static; width: auto; box-shadow: none; border: 0; padding: 0 8px; display: none; }
  .dropdown.open .dropdown-menu { display: block; }
}
@media (max-width: 1100px) {
  /* 中小網：首屏的立即聊聊只留黑色按鈕，不要白色外框 padding */
  .chat-cta { width: 140px; padding: 0; gap: 0; background: transparent; box-shadow: 0 8px 24px rgba(0,0,0,.18); border-radius: 10px; }
  .chat-cta p { display: none; }
}
@media (max-width: 640px) {
  /* 手機：服務流程說明改自然換行、字縮小，左右並排才放得下 */
  .process-intro { gap: 16px; }
  .ptab-lead { font-size: 15px; line-height: 1.8; }
  .sub-lines span { display: inline; }
  .sub-lines span:not(:last-child)::after { content: "，"; }
  .sub-lines span:last-child::after { content: "。"; }
  .principles h4 { font-size: 16px; }
  .principles ul { margin-top: 12px; gap: 8px; }
  .principles li { padding: 12px 14px; font-size: 14px; gap: 8px; }
  /* 手機：文章卡片一張一排 */
  .posts { grid-template-columns: 1fr; }
}
@media (max-width: 900px) {
  .header { left: 16px; right: 16px; top: 16px; }
  .header .logo { width: 150px; height: 27px; }
  .chat-cta { right: 16px; bottom: 16px; }
  .chat-panel { right: 12px; left: 12px; bottom: 12px; width: auto; height: calc(100vh - 24px); }
  .service { padding: 32px 20px; }
  .service-wrap { padding: 12px; }
  .cards { grid-template-columns: 1fr; } /* 手機：卡片填滿寬度 */
  .goals { padding: 100px 16px; gap: 60px; }
  .goals-hint { margin-top: -40px; }
  .chips { gap: 12px; }
  .blog-head { flex-direction: column; align-items: flex-start; }
  .security { padding: 80px var(--gutter); }
  .sec-head .sub { font-size: 16px; }
  .sec-cards { margin-top: 40px; }
  .sec-card { padding: 28px 22px; }
  .sec-card h3 { font-size: 20px; }
  .sec-card ul { font-size: 15px; }
  .steps h3 { font-size: 24px; }
  .steps p { font-size: 16px; }
  .step-link .go { display: none; }
  .post-body { padding: 24px; }
  .post h3 { font-size: 22px; }
}
