/* FootDisc 主題 */
:root {
	--fd-ink: #1e2b33;
	--fd-ink-2: #4a5a63;
	--fd-deep: #142028;
	--fd-blue: #2dafe0;
	--fd-blue-text: #0a76a4;
	--fd-lime: #aecd00;
	--fd-paper: #eef3f5;
	--fd-line: #d3dee3;
	--fd-en: "Barlow Condensed", "Abel", "Arial Narrow", sans-serif;
	--fd-zh: "Noto Sans TC", "PingFang TC", "Microsoft JhengHei", sans-serif;
	--fd-wrap: 1200px;
	--fd-gutter: clamp(16px, 4vw, 40px);
	--fdt-header-h: 76px;
	--fd-hero-offset: 112px; /* 頂部小列 36 + 主列 76，讓首頁主視覺剛好一屏 */
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--fdt-header-h) + 8px); -webkit-text-size-adjust: 100%; }
body { margin: 0; font-family: var(--fd-zh); color: var(--fd-ink); background: #fff; line-height: 1.75; -webkit-font-smoothing: antialiased; }
img { max-width: 100%; height: auto; }
a { color: var(--fd-blue-text); }
:focus-visible { outline: 3px solid var(--fd-blue); outline-offset: 3px; }
.fdt-en { font-family: var(--fd-en); letter-spacing: .02em; }
.fdt-wrap { max-width: var(--fd-wrap); margin-inline: auto; padding-inline: var(--fd-gutter); }
.fdt-skip { position: absolute; left: 12px; top: -60px; z-index: 1000; background: var(--fd-ink); color: #fff; padding: 8px 14px; border-radius: 4px; }
.fdt-skip:focus { top: 12px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

/* ---------- 頂部小列 ---------- */
.fdt-utility { background: var(--fd-ink); color: #c8d4da; font-size: 13px; }
.fdt-utility__in { display: flex; align-items: center; justify-content: space-between; min-height: 36px; gap: 16px; }
.fdt-utility a { color: inherit; text-decoration: none; }
.fdt-utility a:hover { color: #fff; }
.fdt-utility__hotline .fdt-en { font-size: 16px; color: #fff; margin-left: 4px; }
.fdt-utility__nav { display: flex; align-items: center; gap: 24px; }
.fdt-utility__list { display: flex; gap: 20px; margin: 0; padding: 0; list-style: none; }
.fdt-lang { display: flex; gap: 2px; align-items: center; }
.fdt-lang > * { padding: 2px 6px; color: inherit; text-decoration: none; }
.fdt-lang [aria-current] { color: var(--fd-lime); }

/* ---------- 主列 ---------- */
.fdt-header { position: sticky; top: 0; z-index: 100; background: rgba(255,255,255,.96); backdrop-filter: saturate(1.4) blur(8px); border-bottom: 1px solid transparent; transition: border-color .2s; }
.fdt-header.is-stuck { border-bottom-color: var(--fd-line); }
.admin-bar .fdt-header { top: 32px; }
.admin-bar { --fd-hero-offset: 144px; }
.fdt-header__in { display: flex; align-items: center; gap: 24px; height: var(--fdt-header-h); }
.fdt-logo { display: block; flex: none; }
.fdt-logo img { display: block; height: 52px; width: auto; }
.fdt-nav { margin-left: auto; }
.fdt-nav__list { display: flex; gap: clamp(14px, 1.6vw, 26px); margin: 0; padding: 0; list-style: none; }
.fdt-nav__list a { position: relative; display: block; padding: 8px 0; color: var(--fd-ink); text-decoration: none; font-size: 15px; font-weight: 500; white-space: nowrap; }
.fdt-nav__list a::after { content: ""; position: absolute; left: 0; right: 0; bottom: 2px; height: 2px; background: var(--fd-blue); transform: scaleX(0); transform-origin: left; transition: transform .25s; }
.fdt-nav__list a:hover::after, .fdt-nav__list a.is-current::after { transform: scaleX(1); }
.fdt-shop {
	display: inline-flex; align-items: center; justify-content: center; min-height: 42px; padding: 0 20px; border-radius: 999px;
	background: var(--fd-blue); color: var(--fd-ink); font-weight: 700; font-size: 15px; text-decoration: none; white-space: nowrap; transition: background .2s, color .2s;
}
.fdt-shop:hover { background: var(--fd-ink); color: #fff; }
.fdt-account { display: inline-flex; align-items: center; gap: 6px; min-height: 42px; padding: 0 4px; color: var(--fd-ink); text-decoration: none; font-weight: 500; font-size: 15px; white-space: nowrap; }
.fdt-account svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; }
.fdt-account:hover, .fdt-account.is-current { color: var(--fd-blue-text); }
.fdt-drawer__account { display: flex; align-items: center; justify-content: center; min-height: 50px; border-radius: 999px; border: 2px solid var(--fd-ink); color: var(--fd-ink); font-weight: 700; text-decoration: none; }
.fdt-burger { display: none; margin-left: auto; align-items: center; gap: 10px; min-height: 44px; padding: 0 4px; border: 0; background: none; font: inherit; font-weight: 700; color: var(--fd-ink); cursor: pointer; }
.fdt-burger__bars { position: relative; width: 22px; height: 12px; }
.fdt-burger__bars span { position: absolute; left: 0; width: 100%; height: 2px; background: currentColor; transition: transform .25s, top .25s; }
.fdt-burger__bars span:first-child { top: 0; }
.fdt-burger__bars span:last-child { top: 10px; }
.fdt-burger[aria-expanded="true"] .fdt-burger__bars span:first-child { top: 5px; transform: rotate(45deg); }
.fdt-burger[aria-expanded="true"] .fdt-burger__bars span:last-child { top: 5px; transform: rotate(-45deg); }

/* ---------- 手機選單 ---------- */
.fdt-drawer { position: fixed; inset: var(--fdt-drawer-top, 76px) 0 0 0; z-index: 99; background: #fff; overflow-y: auto; padding: 8px var(--fd-gutter) 40px; border-top: 1px solid var(--fd-line); }
.fdt-drawer__list, .fdt-drawer__sub { list-style: none; margin: 0; padding: 0; }
.fdt-drawer__list a { display: block; padding: 14px 0; font-size: 20px; font-weight: 700; color: var(--fd-ink); text-decoration: none; border-bottom: 1px solid var(--fd-line); }
.fdt-drawer__sub { display: flex; flex-wrap: wrap; gap: 8px 24px; margin-top: 20px; }
.fdt-drawer__sub a { color: var(--fd-ink-2); text-decoration: none; font-weight: 500; }
.fdt-drawer__foot { display: grid; gap: 16px; margin-top: 28px; }
.fdt-shop--block { width: 100%; min-height: 50px; }
.fdt-drawer__tel { color: var(--fd-ink); text-decoration: none; }
.fdt-drawer__tel .fdt-en { font-size: 22px; margin-left: 6px; }
.fdt-drawer .fdt-lang { color: var(--fd-ink-2); }
.fdt-drawer .fdt-lang [aria-current] { color: var(--fd-blue-text); font-weight: 700; }
body.fdt-lock { overflow: hidden; }

@media (max-width: 1180px) {
	.fdt-nav, .fdt-header__in > .fdt-shop { display: none; }
	.fdt-account { margin-left: auto; }
	.fdt-header__in .fdt-burger { margin-left: 4px; }
	.fdt-burger { display: inline-flex; }
}
@media (max-width: 760px) {
	:root { --fdt-header-h: 64px; --fd-hero-offset: 64px; }
	.fdt-utility { display: none; }
	.fdt-logo img { height: 44px; }
}
@media (max-width: 782px) { .admin-bar .fdt-header { top: 46px; } }
@media (max-width: 600px) { .admin-bar .fdt-header { top: 0; } }

/* ---------- 一般頁面 ---------- */
.fdt-page { padding-block: clamp(48px, 8vw, 96px); min-height: 50vh; }
.fdt-page__title { font-size: clamp(28px, 3.6vw, 40px); line-height: 1.3; margin: 0 0 24px; }
.fdt-content { max-width: 46em; }
.fdt-notice { padding: 16px 20px; background: var(--fd-paper); border-left: 4px solid var(--fd-blue); }

/* ---------- 頁尾 ---------- */
.fdt-footer { background: var(--fd-deep); color: #a9b9c0; font-size: 14px; padding-top: clamp(48px, 6vw, 72px); }
.fdt-footer a { color: #dfe8ec; text-decoration: none; }
.fdt-footer a:hover { color: var(--fd-blue); }
.fdt-footer__grid { display: grid; grid-template-columns: 1.1fr 1.2fr 1.4fr; gap: 40px clamp(32px, 5vw, 72px); }
.fdt-footer__brand { display: flex; flex-direction: column; gap: 22px; align-items: flex-start; }
.fdt-footer__logo img { display: block; height: 80px; width: auto; }
.fdt-footer__german { width: 140px; }
.fdt-footer__h { margin: 0 0 14px; font-size: 15px; color: #fff; letter-spacing: .06em; }
.fdt-footer__list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 6px 20px; }
.fdt-footer dl { margin: 0; display: grid; gap: 6px; }
.fdt-footer dl > div { display: grid; grid-template-columns: 5em 1fr; gap: 8px; }
.fdt-footer dt { color: #7f939c; }
.fdt-footer dd { margin: 0; color: #dfe8ec; }
.fdt-social { list-style: none; margin: 20px 0 0; padding: 0; display: flex; gap: 10px; }
.fdt-social a { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; border: 1px solid rgba(255,255,255,.2); }
.fdt-social a:hover { border-color: var(--fd-blue); background: var(--fd-blue); color: var(--fd-deep); }
.fdt-social svg { width: 18px; height: 18px; fill: currentColor; }
.fdt-footer__bottom { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; margin-top: 48px; padding-block: 20px 28px; border-top: 1px solid rgba(255,255,255,.1); font-size: 13px; }
.fdt-footer__bottom p { margin: 0; }
.fdt-footer .fdt-lang a { color: #a9b9c0; }

@media (max-width: 900px) {
	.fdt-footer__grid { grid-template-columns: 1fr 1fr; }
	.fdt-footer__brand { grid-column: 1 / -1; flex-direction: row; align-items: center; }
}
@media (max-width: 560px) {
	.fdt-footer__grid { grid-template-columns: 1fr; }
	.fdt-footer__logo img { height: 64px; }
	.fdt-footer { padding-bottom: 72px; } /* 讓出浮動按鈕的位置 */
	.fdt-float { right: 12px; bottom: 12px; }
	.fdt-float__ai img { width: 48px; height: 48px; }
}

/* ---------- 浮動按鈕 ---------- */
/* 智能客服的按鈕固定在右下 20px、直徑 56px（位置寫死在 widget 裡），回頂端按鈕改放在它正上方 */
.fd-has-chat .fdt-float { right: 20px; bottom: 88px; }
@media (max-width: 480px) { .fd-has-chat .fdt-float { right: 12px; bottom: 80px; } }
/* 四元會員 App 的「加入 App」按鈕原本也在右下角，排到客服按鈕左邊並對齊 */
.fd-has-chat .syma-install { right: 88px !important; bottom: 24px !important; }
@media (max-width: 480px) { .fd-has-chat .syma-install { right: 80px !important; bottom: 16px !important; } }
.fdt-float { position: fixed; right: 16px; bottom: 16px; z-index: 90; display: flex; flex-direction: column; align-items: flex-end; gap: 10px; transition: transform .4s cubic-bezier(.2,.7,.2,1); }
.fdt-float.is-lifted { transform: translateY(calc(var(--fdt-lift, 0px) * -1)); }
.fdt-float__ai { display: flex; align-items: center; gap: 0; background: #fff; border-radius: 999px; box-shadow: 0 6px 20px rgba(20, 32, 40, .18); text-decoration: none; color: var(--fd-ink); overflow: hidden; }
.fdt-float__ai img { width: 56px; height: 56px; border-radius: 50%; object-fit: cover; display: block; }
.fdt-float__ai span { max-width: 0; overflow: hidden; white-space: nowrap; font-size: 14px; font-weight: 700; transition: max-width .3s, padding .3s; }
.fdt-float__ai:hover span, .fdt-float__ai:focus-visible span { max-width: 160px; padding: 0 18px 0 12px; }
.fdt-float__top { width: 44px; height: 44px; border-radius: 50%; border: 0; background: var(--fd-ink); color: #fff; display: grid; place-items: center; cursor: pointer; margin-right: 6px; }
.fdt-float__top[hidden] { display: none; }
.fdt-float__top svg { width: 20px; height: 20px; stroke: currentColor; stroke-width: 2.4; fill: none; }

.fdt-toast { position: fixed; left: 50%; bottom: 28px; transform: translateX(-50%); z-index: 9999; background: var(--fd-ink); color: #fff; padding: 10px 20px; border-radius: 999px; font-size: 14px; box-shadow: 0 6px 24px rgba(0,0,0,.2); }
