/* =========================================================
   權錸檢測 CLGS — 全站樣式（方案 A＋B）
   深藍主視覺 → 白色「測試報告」質感內頁，等寬字標註標準號
   修改主題色：只改下方 :root 變數
   ========================================================= */
:root {
  --ink:      #06142a;   /* 深色區底色 */
  --navy:     #0b2545;   /* 品牌深藍 */
  --navy-2:   #1d4477;
  --ice:      #9fbbe0;   /* 深色區次要文字、地球點陣 */
  --paper:    #f5f7fa;   /* 內頁底色 */
  --card:     #ffffff;
  --line:     #dde4ee;
  --text:     #13213a;
  --muted:    #5a6a80;
  --red:      #b3141c;   /* 品牌紅（取自 Logo 酒紅 #7A1216，提高明度供按鈕使用） */
  --red-hi:   #ff4a52;   /* 深底上的紅 */
  --on-dark:  #e9eff8;
  --dim-dark: #a9bcd6;

  --f-display: "Archivo", "Noto Sans TC", "Microsoft JhengHei", system-ui, sans-serif;
  --f-body:    "Noto Sans TC", "Microsoft JhengHei", "PingFang TC", system-ui, sans-serif;
  --f-mono:    "IBM Plex Mono", ui-monospace, "Consolas", monospace;

  --gutter: clamp(16px, 4vw, 56px);
  --max: 1240px;
  --header-h: 74px;
  --ease: cubic-bezier(.2, .7, .1, 1);
  color-scheme: light;
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: auto; -webkit-text-size-adjust: 100%; }
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-stopped { overflow: hidden; }
body {
  margin: 0; background: var(--paper); color: var(--text);
  font-family: var(--f-body); font-size: 16px; line-height: 1.75;
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4 { margin: 0; line-height: 1.25; text-wrap: balance; font-weight: 900; }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }
button { font: inherit; }
:focus-visible { outline: 2px solid var(--red-hi); outline-offset: 3px; border-radius: 4px; }
::selection { background: var(--red); color: #fff; }
.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding-inline: var(--gutter); }
.mono { font-family: var(--f-mono); letter-spacing: .02em; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.kicker { font-family: var(--f-mono); font-size: .78rem; letter-spacing: .16em; text-transform: uppercase; color: var(--red); display: inline-flex; gap: .7em; align-items: center; }
.kicker::before { content: ""; width: 22px; height: 1px; background: currentColor; }
.dark .kicker, .kicker.on-dark { color: var(--red-hi); }

/* ---------- Buttons ---------- */
.btn {
  --bg: var(--red); --fg: #fff; --hover: var(--navy);
  display: inline-flex; align-items: center; gap: 10px; padding: 14px 26px; border-radius: 99px;
  background: var(--bg); color: var(--fg); font-weight: 700; font-size: .95rem; border: 0; cursor: pointer;
  position: relative; overflow: hidden; isolation: isolate; will-change: transform; white-space: nowrap;
  transition: color .35s var(--ease);
}
.btn::before { content: ""; position: absolute; inset: 0; z-index: -1; background: var(--hover); transform: translateY(101%); transition: transform .45s var(--ease); border-radius: inherit; }
.btn:hover::before { transform: none; }
.btn .arr { width: 16px; height: 16px; transition: transform .3s var(--ease); }
.btn:hover .arr { transform: translateX(3px); }
.btn:disabled { opacity: .6; cursor: wait; }
.btn.ghost { --bg: transparent; --fg: var(--on-dark); --hover: var(--on-dark); box-shadow: inset 0 0 0 1px rgba(233,239,248,.35); }
.btn.ghost:hover { color: var(--navy); }
.btn.outline { --bg: transparent; --fg: var(--navy); --hover: var(--navy); box-shadow: inset 0 0 0 1px var(--line); }
.btn.outline:hover { color: #fff; }
.btn.white { --bg: #fff; --fg: var(--red); --hover: var(--ink); }
.btn.white:hover { color: #fff; }
.btn.sm { padding: 10px 18px; font-size: .88rem; }
.link-arrow { font-weight: 700; color: var(--red); display: inline-flex; align-items: center; gap: 8px; }
.link-arrow svg { width: 16px; height: 16px; transition: transform .3s var(--ease); }
.link-arrow:hover svg { transform: translateX(4px); }

/* ---------- Curtain：開場與換頁 ---------- */
.curtain {
  position: fixed; inset: 0; z-index: 300; background: var(--ink); color: var(--on-dark);
  display: grid; place-items: center; transform: translateY(-100%); pointer-events: none;
}
html.is-first .curtain, html.is-entering .curtain { transform: none; animation: curtain-failsafe .01s 3.6s forwards; }
@keyframes curtain-failsafe { to { visibility: hidden; } }
.curtain .inner { display: grid; justify-items: center; gap: 18px; }
.curtain svg { width: 84px; height: 84px; }
.curtain .ring { stroke-dasharray: 140; stroke-dashoffset: 140; }
html.is-entering .curtain .ring { stroke-dashoffset: 0; }
.curtain .grid { opacity: 0; }
html.is-entering .curtain .grid { opacity: 1; }
.curtain .word { height: 34px; width: auto; }
.curtain .pct { font-family: var(--f-mono); font-size: .75rem; color: var(--ice); letter-spacing: .1em; font-variant-numeric: tabular-nums; min-height: 1.2em; }

/* ---------- Header ---------- */
.site-header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  padding-top: env(safe-area-inset-top, 0px);
  color: var(--on-dark); transition: background .4s var(--ease), color .4s var(--ease), box-shadow .4s;
}
.site-header.scrolled { background: rgba(6,20,42,.72); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); }
.site-header.solid { background: rgba(255,255,255,.9); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); color: var(--text); box-shadow: 0 1px 0 var(--line); }
.site-header .wrap { display: flex; align-items: center; gap: 28px; height: var(--header-h); }
.brand { display: flex; align-items: center; gap: 14px; flex-shrink: 0; }
.brand img { height: 30px; width: auto; }
.brand .logo-dark { display: none; }
.site-header.solid .brand .logo-dark { display: block; }
.site-header.solid .brand .logo-light { display: none; }
body.menu-open .site-header .brand .logo-dark { display: none; }
body.menu-open .site-header .brand .logo-light { display: block; }
.brand .zh { font-size: .9rem; font-weight: 700; letter-spacing: .14em; padding-left: 14px; border-left: 1px solid currentColor; line-height: 1.1; opacity: .85; }
.nav { margin-left: auto; display: flex; gap: 4px; height: 100%; }
.nav > li { position: relative; display: flex; align-items: center; }
.nav > li > a { padding: 8px 14px; font-size: .93rem; font-weight: 500; border-radius: 99px; position: relative; opacity: .85; transition: opacity .2s; display: inline-flex; gap: 6px; align-items: center; }
.nav > li > a:hover, .nav > li > a.active { opacity: 1; }
.nav > li > a::after { content: ""; position: absolute; left: 14px; right: 14px; bottom: 2px; height: 1px; background: currentColor; transform: scaleX(0); transform-origin: right; transition: transform .35s var(--ease); }
.nav > li > a:hover::after { transform: scaleX(1); transform-origin: left; }
.nav > li > a.active::after { transform: scaleX(1); background: var(--red-hi); height: 2px; }
.nav .caret { width: 10px; height: 10px; transition: transform .3s var(--ease); }
.nav li:hover .caret, .nav li:focus-within .caret { transform: rotate(180deg); }
.mega {
  position: fixed; left: 50%; top: calc(var(--header-h) + env(safe-area-inset-top, 0px) - 6px); width: min(980px, calc(100vw - 32px));
  transform: translate(-50%, 10px); opacity: 0; visibility: hidden; transition: opacity .3s var(--ease), transform .3s var(--ease), visibility .3s;
  background: var(--card); color: var(--text); border-radius: 18px; padding: 22px; box-shadow: 0 30px 60px -20px rgba(6,20,42,.35), 0 0 0 1px var(--line);
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 4px;
}
.nav li:hover > .mega, .nav li:focus-within > .mega { opacity: 1; visibility: visible; transform: translate(-50%, 0); }
.mega a { display: flex; gap: 14px; padding: 14px; border-radius: 12px; transition: background .2s; }
.mega a:hover { background: var(--paper); }
.mega .mi { flex-shrink: 0; width: 40px; height: 40px; border-radius: 10px; background: var(--paper); color: var(--navy); display: grid; place-items: center; transition: background .2s, color .2s; }
.mega .mi svg { width: 22px; height: 22px; }
.mega a:hover .mi { background: var(--red); color: #fff; }
.mega strong { display: block; font-size: .95rem; }
.mega span.d { display: block; color: var(--muted); font-family: var(--f-mono); font-size: .72rem; line-height: 1.5; margin-top: 2px; }
.header-cta { flex-shrink: 0; }
.site-header.solid .btn.ghost { --fg: var(--text); --hover: var(--navy); box-shadow: inset 0 0 0 1px var(--line); }
.site-header.solid .btn.ghost:hover { color: #fff; }
.nav-toggle { display: none; margin-left: auto; width: 44px; height: 44px; border-radius: 50%; border: 0; background: transparent; color: inherit; cursor: pointer; position: relative; }
.nav-toggle i { position: absolute; left: 12px; right: 12px; height: 2px; background: currentColor; transition: transform .4s var(--ease), top .4s var(--ease); }
.nav-toggle i:nth-child(1) { top: 17px; } .nav-toggle i:nth-child(2) { top: 25px; }
body.menu-open .nav-toggle i:nth-child(1) { top: 21px; transform: rotate(45deg); }
body.menu-open .nav-toggle i:nth-child(2) { top: 21px; transform: rotate(-45deg); }
body.menu-open .site-header { background: transparent; color: var(--on-dark); box-shadow: none; backdrop-filter: none; }

/* 手機選單 */
.mnav {
  position: fixed; inset: 0; z-index: 90; background: var(--ink); color: var(--on-dark);
  padding: calc(var(--header-h) + env(safe-area-inset-top, 0px) + 20px) var(--gutter) calc(30px + env(safe-area-inset-bottom, 0px));
  overflow-y: auto; visibility: hidden; clip-path: inset(0 0 100% 0); transition: clip-path .6s var(--ease), visibility .6s;
  display: grid; align-content: start; gap: 30px;
}
body.menu-open .mnav { visibility: visible; clip-path: inset(0 0 0 0); }
.mnav .big a { display: flex; justify-content: space-between; align-items: baseline; font-size: 2rem; font-weight: 900; padding: 10px 0; border-bottom: 1px solid rgba(159,187,224,.14); }
.mnav .big a small { font-family: var(--f-mono); font-size: .7rem; color: var(--ice); font-weight: 400; letter-spacing: .12em; }
.mnav .svcs { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 16px; }
.mnav .svcs a { font-size: .9rem; color: var(--dim-dark); }
.mnav .contact { font-family: var(--f-mono); font-size: .85rem; color: var(--ice); display: grid; gap: 4px; }

/* ---------- 共用：深色區底紋 ---------- */
.dark { background: var(--ink); color: var(--on-dark); position: relative; overflow: hidden; }
.gridbg::before {
  content: ""; position: absolute; inset: 0; pointer-events: none; opacity: .5;
  background-image: linear-gradient(rgba(159,187,224,.07) 1px, transparent 1px), linear-gradient(90deg, rgba(159,187,224,.07) 1px, transparent 1px);
  background-size: 56px 56px; mask-image: radial-gradient(ellipse at 70% 40%, #000 15%, transparent 75%); -webkit-mask-image: radial-gradient(ellipse at 70% 40%, #000 15%, transparent 75%);
}
.split .line { display: block; overflow: hidden; padding-bottom: .06em; }
.split .ch { display: inline-block; will-change: transform; }
.outline-text { color: transparent; -webkit-text-stroke: 1.5px currentColor; }
.dark .outline-text { -webkit-text-stroke-color: var(--on-dark); }

/* ---------- 首頁主視覺 ---------- */
.hero-grid { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); align-items: center; min-height: min(880px, 100svh); padding-block: 110px 60px; gap: 20px; }
.hero-copy { position: relative; z-index: 2; }
.eyebrow { font-family: var(--f-mono); font-size: .76rem; color: var(--ice); letter-spacing: .08em; display: flex; flex-wrap: wrap; gap: 6px 18px; margin-bottom: 28px; }
.eyebrow span { display: inline-flex; align-items: center; gap: 8px; }
.eyebrow i { width: 6px; height: 6px; border-radius: 50%; background: var(--red-hi); box-shadow: 0 0 10px var(--red-hi); }
.hero h1 { font-size: clamp(2.5rem, 5.6vw, 4.6rem); letter-spacing: .02em; line-height: 1.12; }
.hero .lead { margin-top: 26px; max-width: 30em; color: #b8c8de; font-size: 1.06rem; }
.hero .ctas { margin-top: 36px; display: flex; flex-wrap: wrap; gap: 14px; }
.globe-stage { position: relative; height: min(720px, 78svh); min-height: 420px; }
.globe-stage canvas { position: absolute; top: -10%; left: -8%; width: 128% !important; height: 120% !important; cursor: grab; touch-action: pan-y; }
.globe-stage canvas:active { cursor: grabbing; }
.globe-fallback { position: absolute; inset: 8%; display: none; }
.no-webgl .globe-fallback { display: block; }
.globe-label {
  position: absolute; left: 0; top: 0; z-index: 3; pointer-events: none; white-space: nowrap;
  font-family: var(--f-mono); font-size: .72rem; color: #fff; padding: 4px 10px; border-radius: 99px;
  background: rgba(179,20,28,.92); opacity: 0; transition: opacity .3s;
}
.globe-label::before { content: ""; position: absolute; left: -12px; top: 50%; width: 12px; height: 1px; background: var(--red-hi); }
.globe-card {
  position: absolute; right: 0; bottom: 6%; z-index: 3; width: min(300px, 80%);
  padding: 18px 20px; border-radius: 14px; background: rgba(11,37,69,.55); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(159,187,224,.18);
}
.globe-card .top { display: flex; justify-content: space-between; font-family: var(--f-mono); font-size: .7rem; color: var(--ice); letter-spacing: .12em; }
.globe-card .country { font-size: 1.45rem; font-weight: 900; margin: 6px 0 10px; color: #fff; min-height: 1.3em; }
.globe-card .marks { display: flex; flex-wrap: wrap; gap: 6px; min-height: 28px; }
.globe-card .marks span { font-family: var(--f-mono); font-size: .74rem; padding: 3px 10px; border-radius: 99px; background: rgba(159,187,224,.12); color: #dce7f6; border: 1px solid rgba(159,187,224,.22); }
.globe-card .hint { margin-top: 14px; font-size: .74rem; color: #8ea6c6; display: flex; align-items: center; gap: 8px; }
.globe-card .hint svg { width: 16px; height: 16px; }
.scroll-cue { position: absolute; left: 50%; bottom: 22px; transform: translateX(-50%); font-family: var(--f-mono); font-size: .66rem; letter-spacing: .3em; color: #7f97b8; display: grid; justify-items: center; gap: 8px; }
.scroll-cue i { width: 1px; height: 34px; background: linear-gradient(var(--ice), transparent); animation: cue 2s var(--ease) infinite; transform-origin: top; }
@keyframes cue { 0% { transform: scaleY(0); } 50% { transform: scaleY(1); } 100% { transform: scaleY(1); opacity: 0; } }

/* ---------- 內頁主視覺 ---------- */
.page-hero { padding-block: calc(var(--header-h) + 90px) 70px; }
.page-hero .wrap { position: relative; display: grid; grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr); gap: 40px; align-items: end; }
.crumb { font-family: var(--f-mono); font-size: .74rem; color: #7f97b8; letter-spacing: .1em; display: flex; gap: 10px; margin-bottom: 22px; }
.crumb a:hover { color: #fff; }
.crumb span::before { content: "/"; margin-right: 10px; opacity: .5; }
.page-hero h1 { font-size: clamp(2.6rem, 6.4vw, 5.2rem); line-height: 1.08; letter-spacing: .02em; }
.page-hero h1 .en { display: block; font-family: var(--f-display); font-weight: 800; font-stretch: 120%; font-size: .32em; letter-spacing: .2em; color: var(--red-hi); margin-bottom: 14px; }
.page-hero .lead { color: #b8c8de; font-size: 1.05rem; max-width: 30em; }
.page-hero .meta { margin-top: 22px; display: flex; flex-wrap: wrap; gap: 8px; }
.chip { font-family: var(--f-mono); font-size: .74rem; padding: 4px 12px; border-radius: 99px; border: 1px solid rgba(159,187,224,.25); color: #dce7f6; }
a.chip:hover { border-color: var(--red-hi); color: #fff; }
.page-hero .orbit { position: absolute; right: -180px; top: -140px; width: 520px; height: 520px; border-radius: 50%; border: 1px solid rgba(159,187,224,.12); pointer-events: none; }
.page-hero .orbit::after { content: ""; position: absolute; inset: 70px; border-radius: 50%; border: 1px dashed rgba(159,187,224,.12); }
.page-hero .orbit i { position: absolute; top: 50%; left: -5px; width: 10px; height: 10px; border-radius: 50%; background: var(--red-hi); box-shadow: 0 0 14px var(--red-hi); }

/* 頁內目錄（sticky） */
.subnav { position: sticky; top: calc(var(--header-h) + env(safe-area-inset-top, 0px)); z-index: 50; background: rgba(255,255,255,.92); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
.subnav ul { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; }
.subnav ul::-webkit-scrollbar { display: none; }
.subnav a { display: block; padding: 15px 18px; white-space: nowrap; color: var(--muted); font-weight: 500; font-size: .93rem; position: relative; transition: color .2s; }
.subnav a::after { content: ""; position: absolute; left: 18px; right: 18px; bottom: -1px; height: 2px; background: var(--red); transform: scaleX(0); transition: transform .35s var(--ease); }
.subnav a:hover, .subnav a.active { color: var(--text); }
.subnav a.active::after { transform: scaleX(1); }

/* ---------- 區塊共用 ---------- */
.section { padding-block: clamp(80px, 10vw, 130px); }
.section.white { background: var(--card); }
.sec-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 24px; flex-wrap: wrap; margin-bottom: 52px; }
.sec-head h2 { font-size: clamp(2rem, 4vw, 3.1rem); margin-top: 14px; }
.sec-head p { max-width: 30em; color: var(--muted); }
.dark .sec-head p { color: var(--dim-dark); }

/* 跑馬燈 */
.marquee { background: var(--navy); color: var(--ice); overflow: hidden; border-block: 1px solid rgba(159,187,224,.12); }
.marquee-row { display: flex; width: max-content; padding-block: 16px; }
.marquee-row + .marquee-row { border-top: 1px solid rgba(159,187,224,.1); }
.marquee-row span { font-family: var(--f-mono); font-size: .9rem; white-space: nowrap; padding-inline: 22px; display: inline-flex; align-items: center; gap: 22px; }
.marquee-row span::after { content: "◆"; font-size: .5rem; color: var(--red-hi); }
.marquee-row.alt span { color: #6f8bb1; }

/* 品牌陳述 */
.statement { padding-block: clamp(90px, 14vw, 170px); position: relative; overflow: hidden; }
.bigword { position: absolute; right: -2vw; top: 50%; transform: translateY(-50%); font-family: var(--f-display); font-weight: 800; font-stretch: 125%; font-size: clamp(8rem, 24vw, 22rem); color: transparent; -webkit-text-stroke: 1px var(--line); pointer-events: none; line-height: 1; }
.statement .wrap { position: relative; display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 40px; }
.big-text { font-size: clamp(1.45rem, 2.9vw, 2.35rem); font-weight: 700; line-height: 1.6; color: var(--text); max-width: 26em; }
.statement .meta { font-family: var(--f-mono); font-size: .8rem; color: var(--muted); display: grid; gap: 4px; align-content: start; }
.statement .meta b { color: var(--text); font-weight: 500; }
.statement .more { margin-top: 30px; }

/* 實驗室數字 */
.spec-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-top: 1px solid var(--text); }
.spec { padding: 26px 22px 6px 0; border-right: 1px solid var(--line); min-width: 0; }
.spec + .spec { padding-left: 22px; }
.spec:last-child { border-right: 0; }
.spec .num { font-family: var(--f-display); font-weight: 700; font-stretch: 72%; font-size: clamp(1.9rem, 3.3vw, 3rem); line-height: 1; color: var(--navy); font-variant-numeric: tabular-nums; white-space: nowrap; }
.spec .num small { font-size: .42em; font-weight: 600; margin-left: 4px; color: var(--red); font-stretch: 100%; }
.spec .lbl { margin-top: 12px; font-size: .92rem; font-weight: 700; }
.spec .src { font-family: var(--f-mono); font-size: .72rem; color: var(--muted); margin-top: 2px; }

/* 服務卡片 */
.svc-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; perspective: 1200px; }
.svc {
  --mx: 50%; --my: 50%;
  position: relative; border-radius: 16px; padding: 30px 28px 26px; background: var(--paper);
  border: 1px solid var(--line); min-height: 240px; display: flex; flex-direction: column; gap: 12px;
  transform-style: preserve-3d; will-change: transform; transition: background .3s;
}
.svc::before { content: ""; position: absolute; inset: -1px; border-radius: inherit; pointer-events: none; opacity: 0; transition: opacity .3s; background: radial-gradient(420px circle at var(--mx) var(--my), rgba(179,20,28,.10), transparent 45%); }
.svc::after { content: ""; position: absolute; inset: -1px; border-radius: inherit; pointer-events: none; opacity: 0; transition: opacity .3s; padding: 1px;
  background: radial-gradient(260px circle at var(--mx) var(--my), var(--red), transparent 60%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor; mask-composite: exclude; }
.svc:hover { background: var(--card); }
.svc:hover::before, .svc:hover::after { opacity: 1; }
.svc .idx { font-family: var(--f-mono); font-size: .72rem; color: var(--muted); display: flex; justify-content: space-between; }
.svc .ico { width: 44px; height: 44px; color: var(--navy); }
.svc .ico svg { width: 100%; height: 100%; }
.svc h3 { font-size: 1.22rem; }
.svc h3 span { display: block; font-family: var(--f-display); font-weight: 600; font-stretch: 110%; font-size: .72rem; letter-spacing: .18em; color: var(--red); margin-bottom: 4px; text-transform: uppercase; }
.svc p { color: var(--muted); font-size: .92rem; flex: 1; }
.svc .std { font-family: var(--f-mono); font-size: .74rem; color: var(--navy-2); border-top: 1px dashed var(--line); padding-top: 12px; display: flex; justify-content: space-between; gap: 10px; }
.svc .std svg { width: 16px; height: 16px; flex-shrink: 0; color: var(--red); transition: transform .3s var(--ease); }
.svc:hover .std svg { transform: translateX(4px); }

/* 服務產業 */
.ind-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.ind { padding: 30px 28px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); display: flex; gap: 18px; position: relative; overflow: hidden; }
.ind::before { content: ""; position: absolute; inset: 0; background: var(--ink); transform: scaleY(0); transform-origin: bottom; transition: transform .5s var(--ease); z-index: 0; }
.ind > * { position: relative; z-index: 1; transition: color .4s; }
.ind:hover::before { transform: none; }
.ind:hover h3 { color: #fff; } .ind:hover p { color: var(--dim-dark); } .ind:hover .ii { color: var(--red-hi); }
.ind .ii { width: 38px; height: 38px; color: var(--navy); flex-shrink: 0; }
.ind .ii svg { width: 100%; height: 100%; }
.ind h3 { font-size: 1.05rem; margin-bottom: 4px; }
.ind p { font-size: .88rem; color: var(--muted); }

/* 服務流程 */
.process .head { padding-top: clamp(110px, 11vw, 140px); }
.process h2 { font-size: clamp(2rem, 4vw, 3.1rem); margin-top: 14px; }
.process .head p { color: var(--dim-dark); margin-top: 12px; max-width: 32em; }
.track-wrap { padding-block: 56px clamp(90px, 10vw, 120px); }
.track { display: flex; gap: 22px; padding-inline: var(--gutter); width: max-content; }
.step {
  width: min(420px, 78vw); flex-shrink: 0; border-radius: 18px; padding: 34px 32px; position: relative;
  background: linear-gradient(160deg, rgba(29,68,119,.55), rgba(11,37,69,.35)); border: 1px solid rgba(159,187,224,.16);
  display: grid; gap: 14px; align-content: start; min-height: 300px;
}
.step .n { font-family: var(--f-display); font-weight: 800; font-stretch: 120%; font-size: 4.6rem; line-height: 1; color: transparent; -webkit-text-stroke: 1px rgba(159,187,224,.5); }
.step h3 { font-size: 1.4rem; color: #fff; }
.step p { color: var(--dim-dark); font-size: .95rem; }
.step .tag { justify-self: start; font-family: var(--f-mono); font-size: .72rem; padding: 4px 10px; border-radius: 99px; background: rgba(255,74,82,.14); color: #ff9aa8; }
.progress { position: relative; height: 2px; background: rgba(159,187,224,.14); margin-top: 40px; margin-inline: var(--gutter); }
.progress i { position: absolute; inset: 0; background: var(--red-hi); transform-origin: left; transform: scaleX(0); }

/* 證書卡 */
.accr-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px; }
.cert { position: relative; overflow: hidden; border-radius: 18px; background: var(--card); border: 1px solid var(--line); padding: 34px 34px 30px; display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 8px 26px; }
.cert::after { content: ""; position: absolute; top: 0; bottom: 0; width: 40%; left: -60%; background: linear-gradient(100deg, transparent, rgba(255,255,255,.75), transparent); transform: skewX(-18deg); transition: left .9s var(--ease); pointer-events: none; }
.cert:hover::after { left: 120%; }
.seal { grid-row: span 3; width: 92px; height: 92px; border-radius: 50%; display: grid; place-items: center; border: 1.5px solid var(--navy); color: var(--navy); font-family: var(--f-display); font-weight: 800; font-stretch: 115%; font-size: 1.15rem; position: relative; }
.seal::before { content: ""; position: absolute; inset: 6px; border-radius: 50%; border: 1px dashed var(--line); }
.cert h3 { font-size: 1.3rem; }
.cert dl { margin: 6px 0 0; display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 4px 16px; font-size: .9rem; }
.cert dt { color: var(--muted); }
.cert dd { margin: 0; font-family: var(--f-mono); font-size: .84rem; overflow-wrap: anywhere; }

/* 最新消息 */
.news-list { border-top: 1px solid var(--text); }
.news { display: grid; grid-template-columns: 140px 130px minmax(0, 1fr) 40px; gap: 24px; align-items: center; padding: 26px 0; border-bottom: 1px solid var(--line); position: relative; }
.news::before { content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 1px; background: var(--red); transform: scaleX(0); transform-origin: left; transition: transform .6s var(--ease); }
.news:hover::before { transform: none; }
.news time { font-family: var(--f-mono); font-size: .85rem; color: var(--muted); }
.news .cat { font-family: var(--f-mono); font-size: .72rem; color: var(--red); letter-spacing: .08em; }
.news h3 { font-size: 1.1rem; font-weight: 700; }
.news h3 + p { color: var(--muted); font-size: .9rem; margin-top: 4px; }
.news .go { width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--line); display: grid; place-items: center; transition: background .3s, border-color .3s, color .3s; }
.news .go svg { width: 16px; height: 16px; }
.news:hover .go { background: var(--red); border-color: var(--red); color: #fff; }

/* CTA */
.cta { background: var(--red); color: #fff; position: relative; overflow: hidden; }
.cta .wrap { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 40px; align-items: center; padding-block: clamp(70px, 9vw, 110px); position: relative; }
.cta h2 { font-size: clamp(2rem, 4.4vw, 3.4rem); }
.cta p { margin-top: 12px; color: #ffd9df; }
.cta .contact { display: grid; gap: 14px; justify-items: start; }
.cta .contact .line { font-family: var(--f-mono); font-size: 1.05rem; user-select: all; }
.cta .ring { position: absolute; right: -120px; top: -160px; width: 520px; height: 520px; border-radius: 50%; border: 70px solid rgba(255,255,255,.07); pointer-events: none; }

/* ---------- 關於我們 ---------- */
.intro-grid { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: 64px; align-items: start; }
.intro-grid .body p { color: var(--muted); }
.intro-grid .body p + p { margin-top: 1em; }
.check-list { margin-top: 28px; display: grid; gap: 12px; }
.check-list li { display: flex; gap: 12px; font-weight: 500; }
.check-list li::before { content: ""; flex-shrink: 0; width: 22px; height: 22px; margin-top: 3px; border-radius: 50%;
  background: var(--red) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12l5 5L20 7'/%3E%3C/svg%3E") center / 13px no-repeat; }
.values { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.value { padding: 34px 30px; border-radius: 18px; background: var(--card); border: 1px solid var(--line); display: grid; gap: 12px; align-content: start; }
.value .vi { width: 46px; height: 46px; color: var(--red); }
.value .vi svg { width: 100%; height: 100%; }
.value .en { font-family: var(--f-mono); font-size: .72rem; letter-spacing: .2em; color: var(--muted); }
.value h3 { font-size: 1.35rem; }
.value p { color: var(--muted); }
.timeline { position: relative; max-width: 900px; margin-inline: auto; }
.timeline .rail { position: absolute; left: 150px; top: 8px; bottom: 8px; width: 2px; background: var(--line); }
.timeline .rail i { position: absolute; inset: 0; background: var(--red); transform-origin: top; transform: scaleY(1); }
.timeline li { display: grid; grid-template-columns: 150px minmax(0, 1fr); gap: 48px; padding-bottom: 46px; position: relative; }
.timeline li:last-child { padding-bottom: 0; }
.timeline li::before { content: ""; position: absolute; left: 144px; top: 9px; width: 14px; height: 14px; border-radius: 50%; background: var(--paper); border: 3px solid var(--red); z-index: 1; }
.tl-year { font-family: var(--f-display); font-weight: 800; font-stretch: 90%; font-size: 2rem; line-height: 1.1; color: var(--navy); text-align: right; padding-right: 28px; font-variant-numeric: tabular-nums; }
.tl-body h3 { font-size: 1.15rem; margin-bottom: 4px; }
.tl-body p { color: var(--muted); }

.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 16px; background: var(--card); }
table.data { width: 100%; border-collapse: collapse; font-size: .92rem; min-width: 680px; }
table.data th { text-align: left; font-family: var(--f-mono); font-size: .72rem; letter-spacing: .12em; font-weight: 500; color: var(--muted); padding: 16px 20px; border-bottom: 1px solid var(--text); text-transform: uppercase; }
table.data td { padding: 15px 20px; border-bottom: 1px solid var(--line); vertical-align: top; }
table.data tr:last-child td { border-bottom: 0; }
table.data td:first-child { font-weight: 700; white-space: nowrap; }
table.data td:not(:first-child) { font-family: var(--f-mono); font-size: .82rem; color: var(--navy-2); }
table.data tbody tr { transition: background .2s; }
table.data tbody tr:hover { background: var(--paper); }

/* ---------- 服務項目 ---------- */
.svc-layout { display: grid; grid-template-columns: 240px minmax(0, 1fr); gap: 56px; align-items: start; }
.svc-aside { position: sticky; top: calc(var(--header-h) + 40px); }
.svc-aside .kicker { margin-bottom: 14px; }
.svc-aside ol { counter-reset: s; display: grid; }
.svc-aside a { display: flex; gap: 12px; padding: 9px 0; color: var(--muted); font-size: .92rem; border-left: 2px solid var(--line); padding-left: 16px; transition: color .2s, border-color .2s; }
.svc-aside a span { font-family: var(--f-mono); font-size: .72rem; padding-top: 2px; }
.svc-aside a:hover { color: var(--text); }
.svc-aside a.active { color: var(--text); border-left-color: var(--red); font-weight: 700; }
.svc-block { padding-block: 0 90px; margin-bottom: 90px; border-bottom: 1px solid var(--line); scroll-margin-top: calc(var(--header-h) + 30px); }
.svc-block:last-child { border-bottom: 0; margin-bottom: 0; }
.svc-block .no { font-family: var(--f-mono); font-size: .78rem; color: var(--muted); display: flex; gap: 14px; align-items: center; margin-bottom: 16px; }
.svc-block .no b { font-family: var(--f-display); font-weight: 800; font-stretch: 120%; font-size: 3.2rem; line-height: 1; color: transparent; -webkit-text-stroke: 1px var(--navy-2); }
.svc-block h2 { font-size: clamp(1.8rem, 3.4vw, 2.6rem); }
.svc-block .lead { color: var(--muted); margin-top: 16px; max-width: 40em; }
.svc-block .lead.small { font-size: .93rem; margin-top: 10px; }
.svc-block .acts { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 26px; }
.spec-sheet { margin-top: 36px; border-radius: 16px; background: var(--card); border: 1px solid var(--line); overflow: hidden; }
.spec-sheet h4 { font-family: var(--f-mono); font-size: .72rem; letter-spacing: .14em; color: var(--red); padding: 14px 22px; border-bottom: 1px solid var(--line); font-weight: 500; display: flex; justify-content: space-between; }
.spec-sheet h4 span { color: var(--muted); }
.spec-sheet ul { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.spec-sheet.one ul { grid-template-columns: minmax(0, 1fr); }
.spec-sheet li { padding: 14px 22px; border-bottom: 1px solid var(--line); font-family: var(--f-mono); font-size: .86rem; color: var(--navy); }
.spec-sheet:not(.one) li:nth-child(odd) { border-right: 1px solid var(--line); }
.spec-sheet li span { display: block; font-family: var(--f-body); font-size: .82rem; color: var(--muted); margin-top: 2px; line-height: 1.6; }
.item-grid { margin-top: 18px; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.item { padding: 20px 22px; border-radius: 14px; background: var(--card); border: 1px solid var(--line); transition: border-color .3s, transform .3s var(--ease); }
.item:hover { border-color: var(--red); transform: translateY(-3px); }
.item h3 { font-size: 1rem; display: flex; gap: 10px; align-items: center; margin-bottom: 6px; }
.item h3::before { content: ""; width: 6px; height: 6px; background: var(--red); border-radius: 50%; }
.item p { font-family: var(--f-mono); font-size: .76rem; color: var(--muted); line-height: 1.7; }
.svc-block .table-wrap { margin-top: 18px; }

.faq { max-width: 880px; }
.faq details { border-bottom: 1px solid var(--line); }
.faq details:first-child { border-top: 1px solid var(--text); }
.faq summary { list-style: none; cursor: pointer; padding: 24px 56px 24px 0; font-weight: 700; font-size: 1.05rem; position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; position: absolute; right: 6px; top: 50%; width: 30px; height: 30px; margin-top: -15px; border-radius: 50%; border: 1px solid var(--line);
  background: linear-gradient(var(--red), var(--red)) center / 12px 1.5px no-repeat, linear-gradient(var(--red), var(--red)) center / 1.5px 12px no-repeat; transition: transform .35s var(--ease), background-color .3s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq .ans { overflow: hidden; }
.faq .ans p { color: var(--muted); padding-bottom: 24px; }

/* ---------- 聯絡我們 ---------- */
.contact-grid { display: grid; grid-template-columns: minmax(0, .85fr) minmax(0, 1.35fr); gap: 56px; align-items: start; }
.info-list { border-top: 1px solid var(--text); }
.info-item { display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 16px; padding: 22px 0; border-bottom: 1px solid var(--line); align-items: start; }
.info-item .ic { width: 44px; height: 44px; border-radius: 50%; background: var(--ink); color: var(--on-dark); display: grid; place-items: center; }
.info-item .ic svg { width: 19px; height: 19px; }
.info-item h3 { font-family: var(--f-mono); font-size: .72rem; letter-spacing: .14em; color: var(--muted); font-weight: 500; }
.info-item p { font-weight: 700; margin-top: 2px; overflow-wrap: anywhere; }
.info-item p small { display: block; font-weight: 400; color: var(--muted); font-size: .85rem; }
.copy { margin-left: 8px; font-family: var(--f-mono); font-size: .68rem; padding: 2px 8px; border-radius: 99px; border: 1px solid var(--line); background: transparent; cursor: pointer; color: var(--muted); vertical-align: middle; }
.copy:hover { border-color: var(--red); color: var(--red); }
.form-card { background: var(--card); border-radius: 22px; padding: clamp(26px, 4vw, 44px); border: 1px solid var(--line); box-shadow: 0 30px 60px -40px rgba(6,20,42,.35); }
.form-card h2 { font-size: 1.7rem; }
.form-card > p { color: var(--muted); font-size: .93rem; margin-top: 6px; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px 22px; margin-top: 28px; }
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field.full { grid-column: 1 / -1; }
.field label, .field .lbl { font-size: .86rem; font-weight: 700; }
.field .req { color: var(--red); margin-left: 2px; }
.field input, .field select, .field textarea {
  font: inherit; font-size: .95rem; padding: 12px 2px; border: 0; border-bottom: 1.5px solid var(--line); border-radius: 0;
  background: transparent; color: var(--text); width: 100%; transition: border-color .3s;
}
.field select { appearance: none; -webkit-appearance: none; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%235a6a80' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") right 2px center / 16px no-repeat; padding-right: 26px; }
.field textarea { min-height: 120px; resize: vertical; border: 1.5px solid var(--line); border-radius: 12px; padding: 12px 14px; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--navy); }
.field.invalid input, .field.invalid select, .field.invalid textarea { border-color: var(--red); }
.field .err { font-size: .8rem; color: var(--red); display: none; }
.field.invalid .err { display: block; }
.checks { display: flex; flex-wrap: wrap; gap: 8px; }
.checks label { position: relative; cursor: pointer; }
.checks input { position: absolute; opacity: 0; pointer-events: none; }
.checks span { display: inline-block; font-size: .86rem; font-weight: 500; padding: 7px 14px; border-radius: 99px; border: 1px solid var(--line); transition: background .2s, color .2s, border-color .2s; }
.checks input:checked + span { background: var(--navy); color: #fff; border-color: var(--navy); }
.checks input:focus-visible + span { outline: 2px solid var(--red-hi); outline-offset: 2px; }
.form-foot { display: flex; align-items: center; justify-content: space-between; gap: 16px; margin-top: 30px; flex-wrap: wrap; }
.form-foot small { color: var(--muted); }
.form-msg { display: none; margin-top: 20px; padding: 14px 18px; border-radius: 12px; background: #e9f7ef; color: #1e6b3a; border: 1px solid #b7e2c7; font-size: .93rem; }
.form-msg.show { display: block; }
.form-msg.error { background: #fdecef; color: #a50d26; border-color: #f5b5c0; }
.map-panel { border-radius: 22px; overflow: hidden; min-height: 360px; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
.map-panel .info { padding: clamp(28px, 4vw, 48px); display: grid; gap: 14px; align-content: center; position: relative; z-index: 1; }
.map-panel .info h3 { font-size: 1.6rem; color: #fff; }
.map-panel .info p { color: var(--dim-dark); }
.map-panel .info .addr { font-family: var(--f-mono); color: #fff; font-size: 1rem; }
.map-panel .viz { position: relative; min-height: 300px; }
.map-panel .viz svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.pin-pulse { transform-origin: center; transform-box: fill-box; animation: pin 2.4s var(--ease) infinite; }
@keyframes pin { 0% { transform: scale(.4); opacity: .9; } 100% { transform: scale(2.6); opacity: 0; } }

/* ---------- Footer ---------- */
.site-footer { background: var(--ink); color: #8ea6c6; font-size: .9rem; position: relative; overflow: hidden; }
.footer-top { display: grid; grid-template-columns: minmax(0, 1.4fr) repeat(3, minmax(0, 1fr)); gap: 40px; padding-block: 80px 50px; }
.site-footer .brand { color: var(--on-dark); margin-bottom: 18px; }
.site-footer .brand img { height: 36px; }
.site-footer h4 { font-family: var(--f-mono); font-size: .72rem; letter-spacing: .16em; color: var(--ice); font-weight: 500; margin-bottom: 16px; }
.site-footer ul { display: grid; gap: 8px; }
.site-footer a:hover { color: #fff; }
.footer-word { font-family: var(--f-display); font-weight: 800; font-stretch: 125%; font-size: clamp(5rem, 19vw, 17rem); line-height: .8; color: transparent; -webkit-text-stroke: 1px rgba(159,187,224,.16); letter-spacing: -.01em; padding-inline: var(--gutter); white-space: nowrap; user-select: none; }
.footer-bottom { border-top: 1px solid rgba(159,187,224,.1); }
.footer-bottom .wrap { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding-block: 22px calc(22px + env(safe-area-inset-bottom, 0px)); font-size: .8rem; color: #6f819b; }

/* ---------- Responsive ---------- */
@media (max-width: 1080px) {
  .nav, .header-cta { display: none; }
  .nav-toggle { display: block; }
  .svc-layout { grid-template-columns: minmax(0, 1fr); }
  .svc-aside { display: none; }
  .footer-top { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 980px) {
  .hero-grid { grid-template-columns: minmax(0, 1fr); min-height: 0; padding-block: 120px 40px; }
  .globe-stage { height: 440px; min-height: 0; margin-inline: calc(var(--gutter) * -1); }
  .globe-stage canvas { left: 0; width: 100% !important; }
  .globe-card { right: var(--gutter); bottom: 0; }
  .scroll-cue { display: none; }
  .page-hero .wrap, .statement .wrap, .intro-grid, .contact-grid, .cta .wrap { grid-template-columns: minmax(0, 1fr); gap: 28px; }
  .spec-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .spec:nth-child(2) { border-right: 0; }
  .spec:nth-child(3) { padding-left: 0; }
  .spec:nth-child(n+3) { border-top: 1px solid var(--line); }
  .svc-grid, .ind-grid, .item-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .values, .accr-grid { grid-template-columns: minmax(0, 1fr); }
  .news { grid-template-columns: 110px minmax(0, 1fr) 40px; }
  .news .cat { display: none; }
  .map-panel { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 640px) {
  .hero h1 { font-size: 2.3rem; }
  .globe-stage { height: 500px; }
  .globe-stage canvas { top: 0; height: 74% !important; }
  .globe-card { width: auto; left: var(--gutter); padding: 14px 16px; }
  .globe-card .hint { display: none; }
  .svc-grid, .ind-grid, .item-grid, .form-grid { grid-template-columns: minmax(0, 1fr); }
  .spec .num { font-size: 2rem; }
  .cert { grid-template-columns: minmax(0, 1fr); padding: 26px 22px; }
  .seal { grid-row: auto; width: 72px; height: 72px; font-size: .95rem; }
  .track { flex-direction: column; width: auto; }
  .step { width: auto; min-height: 0; }
  .progress { display: none; }
  .spec-sheet ul { grid-template-columns: minmax(0, 1fr); }
  .spec-sheet li:nth-child(odd) { border-right: 0 !important; }
  .timeline .rail { left: 7px; }
  .timeline li { grid-template-columns: minmax(0, 1fr); gap: 4px; padding-left: 36px; }
  .timeline li::before { left: 1px; }
  .tl-year { text-align: left; padding-right: 0; font-size: 1.6rem; }
  .news { grid-template-columns: minmax(0, 1fr) 40px; gap: 6px 16px; }
  .news time { grid-column: 1 / -1; }
  .footer-top { grid-template-columns: minmax(0, 1fr); padding-block: 60px 30px; }
  .page-hero { padding-block: calc(var(--header-h) + 50px) 50px; }
  .page-hero .orbit { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition-duration: .01s !important; }
  .curtain { display: none; }
}

/* =========================================================
   分頁版新增元件
   ========================================================= */
/* 下拉選單（關於我們） */
.drop {
  position: absolute; top: calc(100% - 4px); left: 50%; min-width: 230px; transform: translate(-50%, 10px);
  opacity: 0; visibility: hidden; transition: opacity .3s var(--ease), transform .3s var(--ease), visibility .3s;
  background: var(--card); color: var(--text); border-radius: 14px; padding: 8px; box-shadow: 0 30px 60px -20px rgba(6,20,42,.35), 0 0 0 1px var(--line);
}
.nav li:hover > .drop, .nav li:focus-within > .drop { opacity: 1; visibility: visible; transform: translate(-50%, 0); }
.drop a { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; padding: 11px 14px; border-radius: 10px; transition: background .2s; }
.drop a:hover, .drop a.on { background: var(--paper); }
.drop a.on strong { color: var(--red); }
.drop strong { font-size: .93rem; }
.drop .d { font-family: var(--f-mono); font-size: .68rem; color: var(--muted); letter-spacing: .08em; }
.mega a.on { background: var(--paper); }
.mega a.on strong { color: var(--red); }
.mega .all { grid-column: 1 / -1; justify-content: space-between; align-items: center; border-top: 1px solid var(--line); border-radius: 0 0 12px 12px; margin-top: 6px; padding: 16px 14px 10px; font-weight: 700; font-size: .9rem; color: var(--red); }
.mega .all svg { width: 18px; height: 18px; }

/* 分頁列（關於我們 4 頁、9 項服務切換） */
.tabbar { position: sticky; top: calc(var(--header-h) + env(safe-area-inset-top, 0px)); z-index: 50; background: rgba(255,255,255,.92); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px); border-bottom: 1px solid var(--line); }
.tabbar ul { display: flex; gap: 2px; overflow-x: auto; scrollbar-width: none; }
.tabbar ul::-webkit-scrollbar { display: none; }
.tabbar a { display: flex; gap: 8px; align-items: baseline; padding: 15px 16px; white-space: nowrap; color: var(--muted); font-weight: 500; font-size: .92rem; position: relative; transition: color .2s; }
.tabbar a span { font-family: var(--f-mono); font-size: .68rem; }
.tabbar a::after { content: ""; position: absolute; left: 16px; right: 16px; bottom: -1px; height: 2px; background: var(--red); transform: scaleX(0); transition: transform .35s var(--ease); }
.tabbar a:hover, .tabbar a.active { color: var(--text); }
.tabbar a.active { font-weight: 700; }
.tabbar a.active::after { transform: scaleX(1); }

/* 分頁標籤按鈕 */
.seg { display: inline-flex; flex-wrap: wrap; gap: 6px; padding: 5px; border-radius: 99px; background: var(--paper); border: 1px solid var(--line); }
.seg button, .chips button {
  border: 0; background: transparent; color: var(--muted); font-weight: 600; font-size: .88rem; padding: 8px 16px; border-radius: 99px; cursor: pointer; transition: background .25s, color .25s;
}
.seg button:hover, .chips button:hover { color: var(--text); }
.seg button.active { background: var(--navy); color: #fff; }
.dark .seg { background: rgba(159,187,224,.08); border-color: rgba(159,187,224,.18); }
.dark .seg button { color: var(--dim-dark); }
.dark .seg button:hover { color: #fff; }
.dark .seg button.active { background: var(--red-hi); color: #fff; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chips button { border: 1px solid var(--line); background: var(--card); }
.chips button.active { background: var(--navy); border-color: var(--navy); color: #fff; }
.chips button .n { font-family: var(--f-mono); font-size: .72rem; opacity: .7; margin-left: 4px; }
[data-panel][hidden] { display: none !important; }

/* 互動實驗室面板 */
.lab { border-radius: 24px; overflow: hidden; position: relative; }
.lab.dark { padding: clamp(24px, 4vw, 48px); }
.lab-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; flex-wrap: wrap; margin-bottom: 28px; }
.lab-head h2 { font-size: clamp(1.6rem, 3vw, 2.3rem); margin-top: 10px; }
.lab-head p { color: var(--dim-dark); max-width: 34em; margin-top: 8px; }
.lab .note { font-family: var(--f-mono); font-size: .7rem; color: #7f97b8; margin-top: 16px; }
.lab-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 24px; align-items: stretch; }
.screen { position: relative; border-radius: 16px; background: #040e1f; border: 1px solid rgba(159,187,224,.16); overflow: hidden; min-height: 320px; }
.screen canvas { display: block; width: 100%; height: 100%; position: absolute; inset: 0; }
.screen .hud { position: absolute; left: 14px; top: 12px; right: 14px; display: flex; justify-content: space-between; font-family: var(--f-mono); font-size: .7rem; color: var(--ice); pointer-events: none; gap: 10px; }
.readout { display: grid; gap: 12px; align-content: start; }
.metric { border-radius: 14px; padding: 16px 18px; background: rgba(159,187,224,.06); border: 1px solid rgba(159,187,224,.14); }
.metric .k { font-family: var(--f-mono); font-size: .7rem; letter-spacing: .12em; color: var(--ice); }
.metric .v { font-family: var(--f-display); font-stretch: 80%; font-weight: 700; font-size: 2rem; line-height: 1.15; color: #fff; font-variant-numeric: tabular-nums; }
.metric .v small { font-size: .45em; color: var(--dim-dark); margin-left: 4px; font-weight: 500; }
.metric p { color: var(--dim-dark); font-size: .86rem; margin-top: 4px; }
.verdict { display: inline-flex; align-items: center; gap: 8px; font-family: var(--f-mono); font-weight: 500; font-size: .8rem; padding: 5px 12px; border-radius: 99px; letter-spacing: .1em; }
.verdict.pass { background: rgba(46,204,113,.14); color: #6ee7a8; }
.verdict.fail { background: rgba(255,74,82,.16); color: #ff9aa0; }
.verdict.info { background: rgba(159,187,224,.12); color: var(--ice); }
.verdict::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.ctrl { display: grid; gap: 8px; }
.ctrl label { font-size: .84rem; color: var(--dim-dark); display: flex; justify-content: space-between; }
.ctrl label b { color: #fff; font-family: var(--f-mono); font-weight: 500; }
input[type=range] { -webkit-appearance: none; appearance: none; width: 100%; height: 4px; border-radius: 99px; background: rgba(159,187,224,.2); outline: none; }
input[type=range]::-webkit-slider-thumb { -webkit-appearance: none; width: 20px; height: 20px; border-radius: 50%; background: var(--red-hi); border: 3px solid #fff; cursor: grab; box-shadow: 0 0 0 6px rgba(255,74,82,.18); }
input[type=range]::-moz-range-thumb { width: 16px; height: 16px; border-radius: 50%; background: var(--red-hi); border: 3px solid #fff; cursor: grab; }
.light-lab input[type=range] { background: var(--line); }
.btn.mini { padding: 9px 16px; font-size: .85rem; }

/* 服務頁區塊 */
.svc-intro { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 56px; align-items: start; }
.svc-intro .lead { color: var(--muted); font-size: 1.04rem; }
.svc-intro .lead + .lead { margin-top: 14px; font-size: .95rem; }
.kv { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); border-top: 1px solid var(--text); }
.kv div { padding: 18px 0; border-bottom: 1px solid var(--line); }
.kv div:nth-child(odd) { padding-right: 18px; border-right: 1px solid var(--line); }
.kv div:nth-child(even) { padding-left: 18px; }
.kv b { display: block; font-family: var(--f-display); font-stretch: 80%; font-size: 1.8rem; line-height: 1.1; color: var(--navy); }
.kv span { font-size: .85rem; color: var(--muted); }
.std-panel { margin-top: 26px; }
.std-panel .spec-sheet { margin-top: 0; }
.pager { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); gap: 14px; }
.pg { border: 1px solid var(--line); border-radius: 16px; padding: 22px 24px; background: var(--card); display: grid; gap: 6px; transition: border-color .3s, transform .3s var(--ease); }
.pg:hover { border-color: var(--red); transform: translateY(-3px); }
.pg .mono { font-size: .7rem; color: var(--muted); letter-spacing: .1em; }
.pg strong { font-size: 1.1rem; }
.pg.next { text-align: right; }
.pg.mid { text-align: center; align-content: center; }

/* 翻面卡片 */
.flip { perspective: 1200px; cursor: pointer; min-height: 220px; }
.flip .face { position: absolute; inset: 0; border-radius: 18px; padding: 24px; backface-visibility: hidden; -webkit-backface-visibility: hidden; transition: transform .8s var(--ease); display: grid; align-content: space-between; }
.flip .front { background: var(--card); border: 1px solid var(--line); }
.flip .back { background: var(--ink); color: var(--on-dark); transform: rotateY(180deg); }
.flip.flipped .front { transform: rotateY(-180deg); }
.flip.flipped .back { transform: rotateY(0); }
.flip { position: relative; }
.flip .hint { font-family: var(--f-mono); font-size: .68rem; color: var(--muted); letter-spacing: .1em; }
.flip .back .hint { color: var(--ice); }
.flip:focus-visible { outline: 2px solid var(--red-hi); outline-offset: 4px; border-radius: 18px; }

/* 元素週期表樣式（RoHS） */
.elements { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; }
.el .front .sym { font-family: var(--f-display); font-weight: 800; font-stretch: 90%; font-size: 2.6rem; line-height: 1; color: var(--navy); }
.el .front .zh { font-weight: 700; }
.el .front .lim { font-family: var(--f-mono); font-size: .8rem; color: var(--red); }
.el .back p { font-size: .86rem; color: var(--dim-dark); }
.el .back b { font-family: var(--f-mono); color: #fff; font-weight: 500; }
.el { min-height: 190px; }

/* 測驗（資安適用性） */
.quiz { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 24px; }
.q-list { display: grid; gap: 10px; }
.q { display: flex; gap: 14px; align-items: flex-start; padding: 16px 18px; border-radius: 14px; border: 1px solid rgba(159,187,224,.18); cursor: pointer; transition: border-color .25s, background .25s; }
.q:hover { border-color: rgba(159,187,224,.4); }
.q input { margin-top: 4px; width: 18px; height: 18px; accent-color: var(--red-hi); flex-shrink: 0; }
.q:has(input:checked) { background: rgba(255,74,82,.08); border-color: var(--red-hi); }
.q b { display: block; color: #fff; }
.q span { color: var(--dim-dark); font-size: .86rem; }
.result-card { border-radius: 14px; padding: 18px 20px; border: 1px solid rgba(159,187,224,.16); display: grid; gap: 4px; transition: opacity .3s, border-color .3s, background .3s; opacity: .45; }
.result-card.on { opacity: 1; border-color: var(--red-hi); background: rgba(255,74,82,.08); }
.result-card .mono { color: var(--ice); font-size: .74rem; }
.result-card b { color: #fff; font-size: 1.1rem; }
.result-card p { color: var(--dim-dark); font-size: .86rem; }

/* IP 代碼解讀 */
.ip-code { font-family: var(--f-display); font-weight: 800; font-stretch: 90%; font-size: clamp(3.4rem, 8vw, 6rem); line-height: 1; color: #fff; letter-spacing: .02em; }
.ip-code span { color: var(--red-hi); }
.digit-row { display: flex; flex-wrap: wrap; gap: 6px; }
.digit-row button { width: 44px; height: 44px; border-radius: 10px; border: 1px solid rgba(159,187,224,.25); background: transparent; color: var(--on-dark); font-family: var(--f-mono); font-size: 1rem; cursor: pointer; transition: background .2s, border-color .2s; }
.digit-row button.active { background: var(--red-hi); border-color: var(--red-hi); color: #fff; }
.digit-row button .cap { display: none; }

/* 前後對照滑桿 */
.compare { position: relative; min-height: 340px; border-radius: 16px; overflow: hidden; background: #040e1f; border: 1px solid rgba(159,187,224,.16); touch-action: pan-y; }
.compare canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.compare .after { position: absolute; inset: 0; clip-path: inset(0 0 0 50%); }
.compare .handle { position: absolute; top: 0; bottom: 0; left: 50%; width: 2px; background: #fff; cursor: ew-resize; }
.compare .handle::after { content: "⟷"; position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 40px; height: 40px; border-radius: 50%; background: #fff; color: var(--ink); display: grid; place-items: center; font-size: 1rem; }
.compare .tag { position: absolute; top: 12px; font-family: var(--f-mono); font-size: .7rem; padding: 4px 10px; border-radius: 99px; }
.compare .tag.l { left: 12px; background: rgba(255,74,82,.2); color: #ffb3b7; }
.compare .tag.r { right: 12px; background: rgba(46,204,113,.18); color: #8ff0bb; }

/* 步驟切換 */
.stepper { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; border-top: 2px solid rgba(159,187,224,.15); }
.stepper button { text-align: left; background: transparent; border: 0; color: var(--dim-dark); padding: 18px 16px 0 0; cursor: pointer; position: relative; font-weight: 700; font-size: .95rem; }
.stepper button::before { content: ""; position: absolute; left: 0; right: 0; top: -2px; height: 2px; background: var(--red-hi); transform: scaleX(0); transform-origin: left; transition: transform .5s var(--ease); }
.stepper button.active { color: #fff; }
.stepper button.active::before, .stepper button.done::before { transform: scaleX(1); }
.stepper button span { display: block; font-family: var(--f-mono); font-size: .7rem; font-weight: 400; color: var(--ice); }
.step-detail { margin-top: 26px; min-height: 140px; }
.step-detail h3 { color: #fff; font-size: 1.3rem; }
.step-detail p { color: var(--dim-dark); margin-top: 8px; max-width: 40em; }

/* 熱點圖（PCB 設計建議） */
.hotspots { position: relative; border-radius: 16px; overflow: hidden; background: #0a3a2a; aspect-ratio: 16 / 9; max-width: 100%; }
.hotspots svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.hs { position: absolute; width: 34px; height: 34px; margin: -17px 0 0 -17px; border-radius: 50%; border: 0; background: var(--red-hi); color: #fff; font-weight: 800; cursor: pointer; box-shadow: 0 0 0 0 rgba(255,74,82,.6); animation: hs 2s infinite; }
@keyframes hs { 70% { box-shadow: 0 0 0 14px rgba(255,74,82,0); } 100% { box-shadow: 0 0 0 0 rgba(255,74,82,0); } }
.hs.active { background: #fff; color: var(--red); }
.hs-info { border-radius: 14px; padding: 20px; background: rgba(159,187,224,.06); border: 1px solid rgba(159,187,224,.14); }
.hs-info h3 { color: #fff; }
.hs-info p { color: var(--dim-dark); margin-top: 6px; font-size: .92rem; }

/* 設備卡片 */
.toolbar { display: flex; flex-wrap: wrap; gap: 14px; justify-content: space-between; align-items: center; margin-bottom: 26px; }
.search { position: relative; }
.search input { font: inherit; font-size: .92rem; padding: 10px 16px 10px 40px; border-radius: 99px; border: 1px solid var(--line); background: var(--card); width: min(280px, 100%); }
.search input:focus { outline: none; border-color: var(--navy); }
.search svg { position: absolute; left: 14px; top: 50%; width: 16px; height: 16px; transform: translateY(-50%); color: var(--muted); }
.count { font-family: var(--f-mono); font-size: .8rem; color: var(--muted); }
.eq-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.eq { border-radius: 18px; background: var(--card); border: 1px solid var(--line); padding: 24px; display: grid; gap: 10px; align-content: start; cursor: pointer; text-align: left; font: inherit; color: inherit; transition: border-color .3s, transform .3s var(--ease); }
.eq:hover { border-color: var(--red); transform: translateY(-3px); }
.eq .cat { font-family: var(--f-mono); font-size: .7rem; letter-spacing: .1em; color: var(--red); }
.eq h3 { font-size: 1.08rem; }
.eq .size { font-family: var(--f-mono); font-size: .78rem; color: var(--muted); }
.eq .big { font-family: var(--f-display); font-stretch: 80%; font-weight: 700; font-size: 1.6rem; color: var(--navy); line-height: 1.1; }
.empty { display: none; text-align: center; color: var(--muted); padding: 40px 0; }
.is-empty .empty { display: block; }
.drawer-back { position: fixed; inset: 0; z-index: 150; background: rgba(6,20,42,.55); opacity: 0; visibility: hidden; transition: opacity .3s, visibility .3s; }
.drawer { position: fixed; z-index: 160; top: 0; right: 0; bottom: 0; width: min(460px, 100%); background: var(--card); padding: calc(30px + env(safe-area-inset-top, 0px)) 30px 30px; transform: translateX(100%); transition: transform .5s var(--ease); overflow-y: auto; display: grid; gap: 18px; align-content: start; }
.drawer.open { transform: none; }
.drawer.open + .drawer-back, .drawer-back.open { opacity: 1; visibility: visible; }
.drawer .close { justify-self: end; width: 40px; height: 40px; border-radius: 50%; border: 1px solid var(--line); background: transparent; cursor: pointer; font-size: 1.2rem; }
.drawer dl { display: grid; gap: 14px; margin: 0; }
.drawer dt { font-family: var(--f-mono); font-size: .7rem; letter-spacing: .12em; color: var(--muted); }
.drawer dd { margin: 2px 0 0; font-weight: 500; }

/* 沿革互動時間軸 */
.years { display: flex; gap: 0; border-bottom: 1px solid var(--line); overflow-x: auto; scrollbar-width: none; }
.years button { flex: 1; min-width: 110px; border: 0; background: transparent; cursor: pointer; padding: 18px 10px; font-family: var(--f-display); font-weight: 800; font-stretch: 90%; font-size: 1.8rem; color: var(--line); position: relative; transition: color .3s; }
.years button:hover { color: var(--muted); }
.years button.active { color: var(--navy); }
.years button::after { content: ""; position: absolute; left: 20%; right: 20%; bottom: -1px; height: 3px; background: var(--red); transform: scaleX(0); transition: transform .4s var(--ease); }
.years button.active::after { transform: scaleX(1); }
.year-panel { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: 40px; padding-top: 40px; align-items: center; min-height: 260px; }
.year-panel .yy { font-family: var(--f-display); font-weight: 800; font-stretch: 120%; font-size: clamp(5rem, 14vw, 10rem); line-height: .9; color: transparent; -webkit-text-stroke: 1.5px var(--navy); }
.year-panel h3 { font-size: 1.6rem; }
.year-panel p { color: var(--muted); margin-top: 10px; }
.year-panel .tags { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 16px; }
.year-panel .tags span { font-family: var(--f-mono); font-size: .74rem; padding: 3px 10px; border-radius: 99px; border: 1px solid var(--line); color: var(--navy-2); }
.timeline-nav { display: flex; gap: 10px; margin-top: 24px; }
.round { width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line); background: var(--card); cursor: pointer; display: grid; place-items: center; }
.round:hover { border-color: var(--red); color: var(--red); }
.round svg { width: 18px; height: 18px; }

/* 證書翻面 */
.cert-flip { min-height: 330px; }
.cert-flip .front { justify-items: center; text-align: center; align-content: center; gap: 14px; }
.cert-flip .front .seal { grid-row: auto; }
.cert-flip .back dl { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 8px 16px; margin: 0; font-size: .9rem; }
.cert-flip .back dt { color: var(--ice); font-family: var(--f-mono); font-size: .74rem; }
.cert-flip .back dd { margin: 0; color: #fff; font-family: var(--f-mono); font-size: .84rem; overflow-wrap: anywhere; }
.countdown { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.countdown div { border-radius: 16px; background: var(--card); border: 1px solid var(--line); padding: 22px; }
.countdown b { display: block; font-family: var(--f-display); font-weight: 700; font-stretch: 80%; font-size: clamp(2.2rem, 5vw, 3.4rem); line-height: 1; color: var(--navy); font-variant-numeric: tabular-nums; }
.countdown span { font-size: .85rem; color: var(--muted); }
.validity { height: 10px; border-radius: 99px; background: var(--line); overflow: hidden; margin-top: 20px; }
.validity i { display: block; height: 100%; background: linear-gradient(90deg, var(--navy), var(--red)); transform-origin: left; }

/* 首頁：關於入口 */
.about-links { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; margin-top: 40px; }
.about-links a { border-radius: 16px; border: 1px solid var(--line); background: var(--card); padding: 22px; display: grid; gap: 30px; transition: border-color .3s, transform .3s var(--ease); }
.about-links a:hover { border-color: var(--red); transform: translateY(-3px); }
.about-links .mono { font-size: .7rem; color: var(--muted); letter-spacing: .12em; }
.about-links strong { font-size: 1.1rem; display: flex; justify-content: space-between; align-items: center; }
.about-links svg { width: 18px; height: 18px; color: var(--red); }

/* 服務總覽：分類 */
.svc-grid .svc[hidden] { display: none; }

@media (max-width: 980px) {
  .lab-grid, .quiz, .svc-intro, .year-panel { grid-template-columns: minmax(0, 1fr); }
  .elements { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .eq-grid, .about-links { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .stepper { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .elements { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .eq-grid, .about-links, .countdown { grid-template-columns: minmax(0, 1fr); }
  .pager { grid-template-columns: minmax(0, 1fr); }
  .pg.next, .pg.mid { text-align: left; }
  .screen { min-height: 260px; }
  .kv { grid-template-columns: minmax(0, 1fr); }
  .kv div:nth-child(odd) { border-right: 0; padding-right: 0; }
  .kv div:nth-child(even) { padding-left: 0; }
}
.lab .globe-stage { margin-inline: 0; }
.lab .globe-stage canvas { top: 0; left: 0; width: 100% !important; height: 100% !important; }
.lab .globe-card { bottom: 4%; }
#globeChips button { padding: 6px 12px; font-size: .82rem; }
[data-cat][hidden] { display: none !important; }
.readout .verdict { justify-self: start; }
.dark .chips button { background: transparent; color: var(--dim-dark); border-color: rgba(159,187,224,.25); }
.dark .chips button:hover { color: #fff; }
.dark .chips button.active { background: var(--red-hi); border-color: var(--red-hi); color: #fff; }
#nocss { display: none !important; }

/* =========================================================
   換頁轉場（js/core.js → transitions）
   ========================================================= */
html.is-entering .curtain .inner { opacity: 0 !important; }
.tx { position: fixed; inset: 0; z-index: 310; overflow: hidden; pointer-events: auto; }
.tx-full { position: absolute; inset: 0; will-change: clip-path, transform; }
.tx-cell { position: absolute; will-change: transform; }
.tx-bit { display: grid; place-items: center; font-family: var(--f-mono); font-size: 11px; color: var(--ice); letter-spacing: .1em; }
.tx-hex { clip-path: polygon(25% 0, 75% 0, 100% 50%, 75% 100%, 25% 100%, 0 50%); }
.tx-ring { position: absolute; border: 2px solid var(--red-hi); border-radius: 50%; transform: translate(-50%, -50%); }
.tx-seam { position: absolute; left: -10%; right: -10%; top: 50%; height: 2px; background: var(--red-hi); box-shadow: 0 0 18px var(--red-hi); }
.tx-label { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); z-index: 2; display: grid; justify-items: center; gap: 14px; text-align: center; color: #fff; width: min(90vw, 900px); }
.tx-label .k { font-family: var(--f-mono); font-size: .78rem; letter-spacing: .2em; color: var(--ice); }
.tx-label .t { display: flex; justify-content: center; flex-wrap: wrap; overflow: hidden; font-weight: 900; font-size: clamp(2.2rem, 6vw, 4.4rem); line-height: 1.15; letter-spacing: .04em; padding-bottom: .05em; }
.tx-label .t i { font-style: normal; display: inline-block; }
.tx-label .bar { width: 64px; height: 2px; background: var(--red-hi); transform-origin: left; }
.about-links.three { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 640px) { .about-links.three { grid-template-columns: minmax(0, 1fr); } }
