/* ==================================================================
   裝管家 DECOVATE AI — 全站共用樣式
   色票依品牌識別板：炭黑 / 石墨灰 / 電光藍 / 銀灰 / 柔白
   ================================================================== */

:root {
    /* 品牌五色 */
    --ink:      #202326;   /* 主色 · 炭黑 */
    --graphite: #3B4145;   /* 輔色 · 石墨灰 */
    --accent:   #3BA7D8;   /* 強調 · 電光藍 */
    --silver:   #A9B0B4;   /* 中性 · 銀灰 */
    --paper:    #F2F2F0;   /* 背景 · 柔白 */

    /* 衍生 */
    --accent-dark:  #2E8CBA;
    --accent-soft:  rgba(59, 167, 216, 0.12);
    --ink-80:  rgba(32, 35, 38, 0.80);
    --ink-60:  rgba(32, 35, 38, 0.60);
    --line:    rgba(32, 35, 38, 0.12);
    --line-dark: rgba(169, 176, 180, 0.18);

    --white: #ffffff;

    /* 排版 */
    --font-zh: "Noto Sans TC", "PingFang TC", "Microsoft JhengHei", sans-serif;
    --font-en: "Poppins", "Inter", system-ui, -apple-system, sans-serif;
    --font-body: var(--font-en), var(--font-zh);

    /* 尺度 */
    --wrap: 1180px;
    --radius: 14px;
    --radius-sm: 8px;
    --shadow: 0 4px 24px rgba(32, 35, 38, 0.08);
    --shadow-lg: 0 18px 48px rgba(32, 35, 38, 0.14);

    --header-h: 72px;
}

/* ── Reset ─────────────────────────────────────────────────────── */

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); }

body {
    margin: 0;
    font-family: "Poppins", "Noto Sans TC", "PingFang TC", "Microsoft JhengHei", system-ui, sans-serif;
    font-size: 16px;
    line-height: 1.75;
    color: var(--ink);
    background: var(--white);
    -webkit-font-smoothing: antialiased;
}

img, svg, video { max-width: 100%; height: auto; display: block; }
a { color: var(--accent-dark); text-decoration: none; }
a:hover { text-decoration: underline; }
h1, h2, h3, h4 { line-height: 1.35; margin: 0 0 .6em; font-weight: 700; letter-spacing: -0.01em; }
h1 { font-size: clamp(2rem, 4.4vw, 3.15rem); }
h2 { font-size: clamp(1.5rem, 2.8vw, 2.1rem); }
h3 { font-size: clamp(1.15rem, 1.8vw, 1.35rem); }
p  { margin: 0 0 1.1em; }
ul, ol { margin: 0 0 1.1em; padding-left: 1.3em; }

.skip-link {
    position: absolute; left: -9999px; top: 0;
    background: var(--ink); color: #fff; padding: 10px 16px; z-index: 999;
}
.skip-link:focus { left: 8px; top: 8px; }

:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }

/* ── Layout ────────────────────────────────────────────────────── */

.wrap { width: min(100% - 40px, var(--wrap)); margin-inline: auto; }
.section { padding: clamp(56px, 8vw, 104px) 0; }
.section--tight { padding: clamp(40px, 5vw, 64px) 0; }
.section--paper { background: var(--paper); }
.section--ink { background: var(--ink); color: var(--paper); }
.section--ink h1, .section--ink h2, .section--ink h3 { color: #fff; }

.section-head { max-width: 760px; margin: 0 auto clamp(32px, 4vw, 56px); text-align: center; }
.section-head p { color: var(--ink-60); font-size: 1.05rem; margin: 0; }
.section--ink .section-head p { color: var(--silver); }

.eyebrow {
    display: inline-block; font-size: .8rem; font-weight: 600; letter-spacing: .16em;
    text-transform: uppercase; color: var(--accent); margin-bottom: 12px;
}

.grid { display: grid; gap: 24px; }
.grid-2 { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.grid-4 { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }

/* ── 品牌 lockup ───────────────────────────────────────────────── */

.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; }
.brand:hover { text-decoration: none; }
.brand-mark { display: block; width: 38px; height: 38px; color: #fff; flex: 0 0 auto; }
.brand-mark svg { width: 100%; height: 100%; }
.brand-text { display: flex; flex-direction: column; line-height: 1.05; }
.brand-zh { font-size: 1.16rem; font-weight: 700; color: #fff; letter-spacing: .06em; }
.brand-en { font-size: .66rem; font-weight: 600; letter-spacing: .13em; color: var(--silver); }
.brand-en em { font-style: normal; color: var(--accent); }

/* ── 按鈕 ──────────────────────────────────────────────────────── */

.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    padding: 12px 24px; border-radius: 999px; border: 1.5px solid transparent;
    font-size: .95rem; font-weight: 600; cursor: pointer; text-decoration: none;
    transition: background .18s ease, color .18s ease, border-color .18s ease, transform .18s ease;
    white-space: nowrap;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }

.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-dark); color: #fff; }

.btn-ink { background: var(--ink); color: #fff; }
.btn-ink:hover { background: var(--graphite); color: #fff; }

.btn-ghost { background: transparent; color: var(--silver); border-color: var(--line-dark); }
.btn-ghost:hover { color: #fff; border-color: var(--silver); }

.btn-outline { background: transparent; color: var(--ink); border-color: var(--line); }
.btn-outline:hover { border-color: var(--ink); }

.btn-lg { padding: 15px 32px; font-size: 1.02rem; }

/* ── 頁首 ──────────────────────────────────────────────────────── */

.site-header {
    position: sticky; top: 0; z-index: 100;
    background: var(--ink);
    border-bottom: 1px solid var(--line-dark);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; min-height: var(--header-h); gap: 20px; }

.primary-nav { display: flex; align-items: center; gap: 28px; }
.nav-list { display: flex; align-items: center; gap: 26px; list-style: none; margin: 0; padding: 0; }
.nav-list a { color: var(--silver); font-size: .94rem; font-weight: 500; text-decoration: none; }
.nav-list a:hover, .nav-list .current-menu-item > a { color: #fff; }
.nav-list li { position: relative; }

/* 下拉 */
.nav-list .sub-menu {
    position: absolute; top: 100%; left: -14px; min-width: 210px;
    background: var(--graphite); border: 1px solid var(--line-dark);
    border-radius: var(--radius-sm); padding: 8px; margin: 0; list-style: none;
    display: none; box-shadow: var(--shadow-lg);
}
.nav-list li:hover > .sub-menu, .nav-list li:focus-within > .sub-menu { display: block; }
.nav-list .sub-menu a { display: block; padding: 8px 12px; border-radius: 6px; font-size: .9rem; }
.nav-list .sub-menu a:hover { background: rgba(255,255,255,.06); }

/* 頁首右側動作：比內文按鈕再收斂一點，不要在導覽列裡搶戲 */
.nav-actions { display: flex; align-items: center; gap: 14px; }

.nav-actions .btn {
    padding: 9px 20px;
    font-size: .875rem;
    letter-spacing: .02em;
}
.nav-actions .btn-primary {
    box-shadow: 0 2px 10px rgba(59,167,216,.28);
}
.nav-actions .btn-primary:hover {
    box-shadow: 0 4px 16px rgba(59,167,216,.36);
}
/* 登入是次要動作：邊框更細更淡，滑過才顯現 */
.nav-actions .btn-ghost {
    border-color: rgba(169,176,180,.26);
    font-weight: 500;
}
.nav-actions .btn-ghost:hover {
    border-color: rgba(169,176,180,.62);
    background: rgba(255,255,255,.04);
}

/* 漢堡：線條收短置中，不要拉滿整個點擊區 */
.nav-toggle {
    display: none; width: 40px; height: 40px; background: none; border: 0; cursor: pointer;
    flex-direction: column; align-items: center; justify-content: center; gap: 4px; padding: 0;
}
.nav-toggle span { display: block; width: 22px; height: 2px; background: #fff; border-radius: 2px; transition: transform .2s, opacity .2s; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

/* 桌機不顯示抽屜專用元件。
   .submenu-toggle 是 JS 為手風琴注入的按鈕，桌機用不到 ——
   少了這行它會以瀏覽器預設按鈕樣式露出來（就是「知識庫」下面那條白底）。 */
.drawer-head, .drawer-close, .drawer-scrim, .app-tabbar, .submenu-toggle { display: none; }
.drawer-body { display: contents; }

/* 桌機：有子選單的項目補一個向下箭頭，讓人知道這裡可以展開 */
@media (min-width: 961px) {
    .nav-list > li.menu-item-has-children > a {
        display: inline-flex; align-items: center; gap: 6px;
    }
    .nav-list > li.menu-item-has-children > a::after {
        content: "";
        width: 7px; height: 7px;
        border-right: 1.6px solid currentColor;
        border-bottom: 1.6px solid currentColor;
        transform: translateY(-2px) rotate(45deg);
        transition: transform .2s ease;
        opacity: .75;
    }
    .nav-list > li.menu-item-has-children:hover > a::after,
    .nav-list > li.menu-item-has-children:focus-within > a::after {
        transform: translateY(1px) rotate(-135deg);
        opacity: 1;
    }
}

/* ── 手機：右側滑出抽屜 + 底部 Tab Bar ────────────────────────── */

@media (max-width: 960px) {

    .nav-toggle { display: flex; }

    /* 抽屜本體 */
    .primary-nav {
        position: fixed; top: 0; right: 0; bottom: 0; left: auto;
        width: min(88vw, 380px);
        z-index: 200;
        background: var(--ink);
        border-left: 1px solid var(--line-dark);
        box-shadow: -18px 0 48px rgba(0,0,0,.42);
        display: flex; flex-direction: column; align-items: stretch; gap: 0;
        padding: 0;
        transform: translateX(100%);
        transition: transform .28s cubic-bezier(.4,0,.2,1);
        overscroll-behavior: contain;
    }
    .primary-nav.is-open { transform: translateX(0); }

    /* .site-header 是 sticky + z-index:100，本身就是一個 stacking context，
       抽屜的 z-index:200 只在它裡面有效，對外層的遮罩無效。
       開啟時把整個 header 抬到遮罩之上，抽屜才蓋得住遮罩。 */
    body.drawer-open .site-header { z-index: 210; }

    /* 遮罩 */
    .drawer-scrim {
        display: block; position: fixed; inset: 0; z-index: 190;
        background: rgba(20,23,26,.62);
        backdrop-filter: blur(2px);
        opacity: 0; transition: opacity .28s ease;
    }
    /* 必要：上面的 display:block 特異度高過 [hidden] 的 UA 樣式，
       沒有這行的話遮罩會一直存在並攔截漢堡鈕的點擊。 */
    .drawer-scrim[hidden] { display: none; }
    .drawer-scrim.is-open { opacity: 1; }

    /* 抽屜頁首 */
    .drawer-head {
        display: flex; align-items: center; justify-content: space-between; gap: 12px;
        padding: 16px 20px;
        background: linear-gradient(135deg, #2A2F33, var(--graphite));
        border-bottom: 1px solid var(--line-dark);
        flex: 0 0 auto;
    }
    .brand--drawer .brand-mark { width: 34px; height: 34px; }

    .drawer-close {
        display: grid; place-items: center;
        width: 42px; height: 42px; flex: 0 0 auto;
        border-radius: 50%; border: 1px solid var(--line-dark);
        background: rgba(255,255,255,.06); color: #fff; cursor: pointer;
        transition: background .18s ease;
    }
    .drawer-close:hover { background: rgba(255,255,255,.12); }
    .drawer-close svg { width: 20px; height: 20px; }

    /* 選單區（可捲動） */
    .drawer-body {
        display: block; flex: 1 1 auto; overflow-y: auto;
        padding: 8px 20px; -webkit-overflow-scrolling: touch;
    }

    .nav-list { flex-direction: column; align-items: stretch; gap: 0; }
    .nav-list > li { border-bottom: 1px solid rgba(169,176,180,.14); }
    .nav-list > li:last-child { border-bottom: 0; }
    .nav-list > li > a {
        display: block; padding: 20px 4px;
        font-size: 1.12rem; font-weight: 700; color: #fff; letter-spacing: .02em;
    }
    .nav-list > li.current-menu-item > a,
    .nav-list > li.current-page-ancestor > a { color: var(--accent); }

    /* 有子選單：右側展開鈕 */
    .nav-list > li.menu-item-has-children { position: relative; }
    .nav-list > li.menu-item-has-children > a { padding-right: 56px; }

    .submenu-toggle {
        position: absolute; top: 14px; right: 0;
        width: 38px; height: 38px; display: grid; place-items: center;
        border: 0; border-radius: 10px; cursor: pointer;
        background: rgba(255,255,255,.07); color: var(--accent);
        transition: background .18s ease, transform .22s ease;
    }
    .submenu-toggle svg { width: 18px; height: 18px; }
    .submenu-toggle[aria-expanded="true"] { transform: rotate(180deg); background: rgba(59,167,216,.18); }

    /* 子選單：手風琴 */
    .nav-list .sub-menu {
        position: static; display: none; background: none; border: 0; box-shadow: none;
        padding: 0 0 14px 4px; margin: 0;
    }
    .nav-list li.is-expanded > .sub-menu { display: block; }
    .nav-list .sub-menu a {
        display: block; padding: 11px 12px; border-radius: 8px;
        font-size: .96rem; font-weight: 500; color: var(--silver);
    }
    .nav-list .sub-menu a:hover { background: rgba(255,255,255,.06); color: #fff; }

    /* 抽屜底部動作區 */
    .nav-actions {
        flex: 0 0 auto;
        display: grid; gap: 10px;
        padding: 18px 20px calc(18px + env(safe-area-inset-bottom));
        border-top: 1px solid var(--line-dark);
        background: rgba(255,255,255,.03);
    }
    .nav-actions .btn { width: 100%; padding: 14px 20px; }

    /* 抽屜開啟時鎖住背景捲動 */
    body.drawer-open { overflow: hidden; }

    /* ── 底部 Tab Bar ── */

    .app-tabbar {
        position: fixed; left: 0; right: 0; bottom: 0; z-index: 140;
        display: grid; grid-auto-flow: column; grid-auto-columns: 1fr;
        background: rgba(255,255,255,.97);
        backdrop-filter: saturate(1.4) blur(8px);
        -webkit-backdrop-filter: saturate(1.4) blur(8px);
        box-shadow: 0 -6px 24px rgba(32,35,38,.10);
        padding-bottom: env(safe-area-inset-bottom);
        border-top: 1px solid rgba(32,35,38,.06);
    }

    .app-tab {
        position: relative;
        display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px;
        padding: 9px 4px 10px;
        font-size: .72rem; font-weight: 600; line-height: 1;
        color: #6E767B; text-decoration: none;
        transition: color .18s ease;
        -webkit-tap-highlight-color: transparent;
    }
    .app-tab:hover, .app-tab:active { text-decoration: none; }
    .app-tab svg { width: 21px; height: 21px; }

    /* 目前所在：上緣指示條 + 主色 */
    .app-tab.is-active { color: var(--ink); }
    .app-tab.is-active::before {
        content: ""; position: absolute; top: 0; left: 50%; transform: translateX(-50%);
        width: 30px; height: 3px; border-radius: 0 0 3px 3px; background: var(--accent);
    }

    /* 最後一項固定為 CTA */
    .app-tab--cta { color: var(--accent-dark); }
    .app-tab--cta svg { color: var(--accent); }

    /* 內容要避開 tab bar，否則頁尾會被蓋住 */
    body { padding-bottom: calc(56px + env(safe-area-inset-bottom)); }

    /* 抽屜開啟時 tab bar 要讓位（抽屜 z-index 200 > 140，這裡再淡出避免視覺打架） */
    body.drawer-open .app-tabbar { opacity: 0; pointer-events: none; }
    .app-tabbar { transition: opacity .2s ease; }
}

@media (prefers-reduced-motion: reduce) {
    .primary-nav, .drawer-scrim, .submenu-toggle, .app-tabbar { transition: none !important; }
}

/* ── 卡片 ──────────────────────────────────────────────────────── */

.card {
    background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
    padding: 28px; transition: transform .2s ease, box-shadow .2s ease;
}
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.card h3 { margin-bottom: .45em; }
.card p { color: var(--ink-60); margin: 0; font-size: .95rem; }

.section--ink .card { background: var(--graphite); border-color: var(--line-dark); }
.section--ink .card p { color: var(--silver); }

.card-icon {
    width: 46px; height: 46px; border-radius: 12px; margin-bottom: 16px;
    display: grid; place-items: center; background: var(--accent-soft); color: var(--accent);
}
.card-icon svg { width: 24px; height: 24px; }
.section--ink .card-icon { background: rgba(59,167,216,.18); }

/* ── 頁面 hero（內頁通用） ─────────────────────────────────────── */

.page-hero {
    background: var(--ink); color: var(--paper);
    padding: clamp(48px, 6vw, 80px) 0 clamp(40px, 5vw, 64px);
}
.page-hero h1 { color: #fff; margin-bottom: .35em; }
.page-hero .lede { color: var(--silver); font-size: 1.1rem; max-width: 720px; margin: 0; }

/* ── 麵包屑 ────────────────────────────────────────────────────── */

.breadcrumb { font-size: .84rem; margin-bottom: 18px; }
.breadcrumb ol { list-style: none; display: flex; flex-wrap: wrap; gap: 8px; margin: 0; padding: 0; }
.breadcrumb li + li::before { content: "/"; margin-right: 8px; color: var(--silver); }
.breadcrumb a { color: var(--silver); }
.breadcrumb [aria-current] { color: var(--ink-60); }
.page-hero .breadcrumb a { color: var(--silver); }
.page-hero .breadcrumb [aria-current] { color: #fff; }

/* ── 表單 ──────────────────────────────────────────────────────── */

.form-grid { display: grid; gap: 18px; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); }
.form-row--full { grid-column: 1 / -1; }

.field label { display: block; font-weight: 600; font-size: .92rem; margin-bottom: 6px; }
.field .req { color: var(--accent); margin-left: 3px; }
.field input, .field textarea, .field select {
    width: 100%; padding: 12px 14px; font: inherit; font-size: .95rem;
    border: 1.5px solid var(--line); border-radius: var(--radius-sm);
    background: #fff; color: var(--ink); transition: border-color .15s;
}
.field input:focus, .field textarea:focus, .field select:focus { border-color: var(--accent); outline: none; }
.field textarea { resize: vertical; min-height: 110px; }
.field .hint { font-size: .82rem; color: var(--ink-60); margin: 5px 0 0; }
.field .error { font-size: .82rem; color: #c0392b; margin: 5px 0 0; display: none; }
.field.has-error input, .field.has-error textarea { border-color: #c0392b; }
.field.has-error .error { display: block; }

/* honeypot：對真人完全不可見，但機器人看得到 */
.hp-field {
    position: absolute !important; left: -9999px !important;
    width: 1px; height: 1px; overflow: hidden;
}

.form-note { font-size: .85rem; color: var(--ink-60); }
.form-status { margin-top: 16px; padding: 14px 16px; border-radius: var(--radius-sm); display: none; font-size: .93rem; }
.form-status.is-error { display: block; background: #fdecea; color: #a4271b; }
.form-status.is-ok { display: block; background: var(--accent-soft); color: var(--accent-dark); }

/* ── 頁尾 ──────────────────────────────────────────────────────── */

.site-footer { background: var(--ink); color: var(--silver); padding: clamp(48px, 6vw, 72px) 0 28px; }
.footer-top { display: grid; grid-template-columns: minmax(240px, 1.1fr) 2fr; gap: 40px; }
@media (max-width: 800px) { .footer-top { grid-template-columns: 1fr; } }

.footer-tagline { margin: 18px 0 10px; font-size: .92rem; line-height: 1.7; }
.footer-contact a { color: var(--accent); font-size: .92rem; }

.footer-cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 32px; }
.footer-heading { font-size: .82rem; letter-spacing: .12em; text-transform: uppercase; color: #fff; margin-bottom: 14px; }
.footer-list { list-style: none; margin: 0; padding: 0; }
.footer-list li { margin-bottom: 9px; }
.footer-list a { color: var(--silver); font-size: .92rem; }
.footer-list a:hover { color: #fff; }

.footer-bottom {
    margin-top: 44px; padding-top: 20px; border-top: 1px solid var(--line-dark);
    display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; align-items: center;
}
.copyright { margin: 0; font-size: .84rem; }
.footer-legal { list-style: none; display: flex; gap: 20px; margin: 0; padding: 0; }
.footer-legal a { color: var(--silver); font-size: .84rem; }

/* ── CTA 區塊 ──────────────────────────────────────────────────── */

.cta-band {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    border-radius: var(--radius);
    padding: clamp(40px, 5vw, 64px) clamp(24px, 5vw, 56px) clamp(92px, 11vw, 132px);
    color: #fff;
    text-align: center;
    background:
        radial-gradient(120% 90% at 50% -10%, #2C3237 0%, transparent 60%),
        linear-gradient(135deg, var(--ink) 0%, #2A2F33 55%, var(--graphite) 100%);
}

/* 室內線稿：貼齊底部、向上淡出，不跟文字搶 */
.cta-band .room-scene {
    position: absolute; inset: auto 0 0 0;
    width: 100%; height: clamp(150px, 20vw, 230px);
    z-index: -1; pointer-events: none;
    color: var(--accent);
    opacity: .30;
    mask-image: linear-gradient(180deg, transparent 0%, #000 46%, #000 88%, transparent 100%);
    -webkit-mask-image: linear-gradient(180deg, transparent 0%, #000 46%, #000 88%, transparent 100%);
}

/* 藍光暈：讓深底不會死板 */
.cta-glow {
    position: absolute; z-index: -1; pointer-events: none;
    left: 50%; bottom: -46%;
    width: min(760px, 96%); aspect-ratio: 2 / 1;
    transform: translateX(-50%);
    background: radial-gradient(ellipse at center, rgba(59,167,216,.30), transparent 66%);
}

.cta-content { position: relative; }
.cta-band h2 { color: #fff; margin-bottom: .4em; }
.cta-band p { color: var(--silver); max-width: 560px; margin: 0 auto 26px; }
.cta-actions { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; }

/*
 * 之後若拿到實拍照片，改用這個變體即可：
 *   <div class="cta-band cta-band--photo" style="--cta-photo:url(...)">
 * 線稿會自動隱藏，並套上足夠的暗色遮罩讓白字維持對比。
 * 照片建議：暖色調室內實景、構圖留白在中央、寬高比約 3:1、寬度 ≥ 1600px。
 */
.cta-band--photo {
    background-image:
        linear-gradient(180deg, rgba(32,35,38,.86), rgba(32,35,38,.78)),
        var(--cta-photo);
    background-size: cover;
    background-position: center;
}
.cta-band--photo .room-scene { display: none; }

/* ── 分頁 ──────────────────────────────────────────────────────── */

.pagination { display: flex; gap: 8px; justify-content: center; margin-top: 48px; flex-wrap: wrap; }
.pagination .page-numbers {
    display: grid; place-items: center; min-width: 40px; height: 40px; padding: 0 12px;
    border: 1px solid var(--line); border-radius: var(--radius-sm); color: var(--ink); text-decoration: none;
}
.pagination .page-numbers.current { background: var(--ink); color: #fff; border-color: var(--ink); }
.pagination .page-numbers:hover { border-color: var(--accent); text-decoration: none; }

/* ── 工具 class ────────────────────────────────────────────────── */

.text-center { text-align: center; }
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }
.screen-reader-text {
    position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(1px,1px,1px,1px); white-space: nowrap;
}

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

/* ── 文章卡片（首頁與列表共用，故放在 base） ──────────────────── */

.article-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; transition: transform .2s ease, box-shadow .2s ease; }
.article-card:hover { transform: translateY(-3px); box-shadow: var(--shadow); }
.article-card-link { display: flex; flex-direction: column; height: 100%; color: inherit; text-decoration: none; }
.article-card-link:hover { text-decoration: none; }

.article-card-media { aspect-ratio: 16 / 9; background: var(--paper); display: grid; place-items: center; overflow: hidden; }
.article-card-media img { width: 100%; height: 100%; object-fit: cover; }
.article-card-fallback { color: var(--silver); }
.article-card-fallback svg { width: 40px; height: 40px; }

.article-card-body { padding: 22px; display: flex; flex-direction: column; flex: 1; }
.article-card-cat { display: inline-block; align-self: flex-start; font-size: .74rem; font-weight: 600; letter-spacing: .04em; color: var(--accent-dark); background: var(--accent-soft); padding: 3px 10px; border-radius: 999px; margin-bottom: 12px; }
.article-card-title { font-size: 1.06rem; margin-bottom: .5em; line-height: 1.5; }
.article-card-excerpt { font-size: .9rem; color: var(--ink-60); margin-bottom: 16px; }
.article-card-meta { margin-top: auto; display: flex; gap: 7px; align-items: center; font-size: .8rem; color: var(--silver); }

/* ── 窄版容器（文章與表單頁） ─────────────────────────────────── */

.wrap--narrow { width: min(100% - 40px, 780px); }

/* ── 勾選清單（產品／情境／試用頁共用） ───────────────────────── */

.check-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 11px; }
.check-list li { display: flex; align-items: flex-start; gap: 9px; font-size: .93rem; }
.check-list svg { width: 18px; height: 18px; color: var(--accent); flex: 0 0 auto; margin-top: 5px; }
.section--ink .check-list li { color: var(--paper); }

/* ── 提示框 ────────────────────────────────────────────────────── */

.notice-box {
    background: var(--accent-soft); border: 1px solid rgba(59,167,216,.28);
    border-radius: var(--radius); padding: 22px 26px;
}
.notice-box p:last-child { margin-bottom: 0; }
.notice-box--dark { background: rgba(59,167,216,.10); border-color: rgba(59,167,216,.30); color: var(--paper); }

/* ── FAQ ───────────────────────────────────────────────────────── */

.faq-list { display: grid; gap: 12px; }
.faq-item { background: #fff; border: 1px solid var(--line); border-radius: var(--radius-sm); overflow: hidden; }
.faq-item + .faq-item { margin-top: 12px; }
.faq-item summary {
    cursor: pointer; padding: 16px 20px; font-weight: 600; font-size: .98rem;
    list-style: none; display: flex; justify-content: space-between; gap: 16px; align-items: center;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: "+"; color: var(--accent); font-size: 1.3rem; font-weight: 400; flex: 0 0 auto; }
.faq-item[open] summary::after { content: "–"; }
.faq-answer { padding: 0 20px 18px; color: var(--ink-60); font-size: .94rem; }
.faq-answer p:last-child { margin-bottom: 0; }

/* ── 主題導覽（部落格首頁） ───────────────────────────────────── */

.topic-nav { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; }
.topic-chip {
    display: flex; flex-direction: column; gap: 2px; padding: 14px 22px;
    background: #fff; border: 1px solid var(--line); border-radius: var(--radius-sm);
    color: var(--ink); text-decoration: none; transition: border-color .18s, transform .18s;
}
.topic-chip:hover { border-color: var(--accent); transform: translateY(-2px); text-decoration: none; }
.topic-chip strong { font-size: .96rem; }
.topic-chip span { font-size: .78rem; color: var(--silver); }

.hero-count { color: var(--silver); font-size: .88rem; margin: 14px 0 0; }

/* ── 產品頁模組 ───────────────────────────────────────────────── */

.module-list { display: grid; gap: 20px; }
.module { border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; background: #fff; }
.module-head { display: flex; gap: 18px; align-items: flex-start; margin-bottom: 18px; }
.module-head .card-icon { margin-bottom: 0; flex: 0 0 auto; }
.module-head h2 { font-size: 1.4rem; margin: 2px 0 .2em; }
.module-index { font-size: .74rem; font-weight: 700; letter-spacing: .14em; color: var(--accent); }
.module-sub { margin: 0; font-size: .9rem; color: var(--ink-60); }
.module-body { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: 28px; align-items: start; }
@media (max-width: 800px) { .module-body { grid-template-columns: 1fr; gap: 18px; } }
.module-desc { margin: 0; color: var(--ink-80); }

/* ── 角色情境 ─────────────────────────────────────────────────── */

.role-block { border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; background: #fff; }
.role-block + .role-block { margin-top: 20px; }
.role-block-head { display: flex; gap: 18px; align-items: center; margin-bottom: 20px; }
.role-block-head .card-icon { margin-bottom: 0; flex: 0 0 auto; }
.role-block-head h2 { font-size: 1.35rem; margin: 0 0 .15em; }
.role-goal { margin: 0; color: var(--ink-60); font-size: .93rem; }
.role-block-body { display: grid; grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr); gap: 28px; align-items: start; }
@media (max-width: 800px) { .role-block-body { grid-template-columns: 1fr; } }
.role-block-quote {
    margin: 0; padding: 18px 20px; background: var(--paper);
    border-left: 3px solid var(--accent); border-radius: 0 8px 8px 0;
    font-size: .96rem; color: var(--ink-80);
}
.role-detail h3 { font-size: .82rem; letter-spacing: .1em; text-transform: uppercase; color: var(--silver); margin-bottom: .5em; }
.role-detail h3 + p { font-size: .93rem; color: var(--ink-80); }
.role-detail h3:not(:first-child) { margin-top: 22px; }

/* ── 流程線 ───────────────────────────────────────────────────── */

.flow-line { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; counter-reset: flow; }
.flow-line li {
    counter-increment: flow; position: relative; padding: 12px 22px;
    background: var(--graphite); border: 1px solid var(--line-dark); border-radius: 999px;
    font-size: .92rem; color: var(--paper);
}
.flow-line li::before { content: counter(flow) ". "; color: var(--accent); font-weight: 700; }

/* ── 試用頁 ───────────────────────────────────────────────────── */

.trial-split { display: grid; grid-template-columns: minmax(0, 1.35fr) minmax(0, .65fr); gap: clamp(28px, 4vw, 52px); align-items: start; }
@media (max-width: 900px) { .trial-split { grid-template-columns: 1fr; } }

.trial-side { display: grid; gap: 16px; position: sticky; top: calc(var(--header-h) + 24px); }
@media (max-width: 900px) { .trial-side { position: static; } }
.trial-card { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; }
.trial-card h3 { font-size: 1.05rem; margin-bottom: .7em; }
.trial-card--quiet { background: #fff; }
.trial-card--quiet p { font-size: .92rem; color: var(--ink-60); margin-bottom: .4em; }

.step-list { margin: 0; padding-left: 1.2em; display: grid; gap: 12px; }
.step-list li { font-size: .92rem; }
.step-list strong { display: block; }
.step-list span { color: var(--ink-60); font-size: .87rem; }

.form-submit { margin-top: 26px; display: flex; flex-direction: column; gap: 12px; align-items: flex-start; }
.form-submit .btn:disabled { opacity: .55; cursor: not-allowed; transform: none; }

/* ── 搜尋表單 ─────────────────────────────────────────────────── */

.search-form { display: flex; gap: 8px; }
.search-form input[type="search"] {
    flex: 1; padding: 12px 14px; font: inherit; border: 1.5px solid var(--line);
    border-radius: var(--radius-sm); background: #fff;
}
.search-form input[type="search"]:focus { border-color: var(--accent); outline: none; }
