:root {
    --color-primary: #123b5d;
    --color-primary-dark: #082a45;
    --color-secondary: #1f679a;
    --color-accent: #f47a2a;
    --color-accent-light: #ffb067;
    --color-background: #f3f6f8;
    --color-surface: #fff;
    --color-white: #fff;
    --color-text: #243b4c;
    --color-muted: #667987;
    --color-border: #dbe4ea;
    --color-icon-background: #edf4f8;
    --color-serial: #d7e2ea;
    --color-serial-strong: #a6bac9;
    --color-footer-muted: #aec1cf;
    --color-text-link: #c55216;
    --color-focus: #f47a2a;
    --font-body: "Noto Sans TC", "Microsoft JhengHei", "PingFang TC", sans-serif;
    --font-display: "Noto Serif TC", "Songti TC", "PMingLiU", serif;
    --font-size-small: .875rem;
    --font-size-body: 1rem;
    --font-size-card: clamp(1.08rem, 1rem + .25vw, 1.3rem);
    --font-size-heading: clamp(1.8rem, 1.38rem + 1.2vw, 2.65rem);
    --font-size-hero: clamp(2.65rem, 1.8rem + 2.7vw, 5.1rem);
    --font-weight-normal: 400;
    --font-weight-semibold: 600;
    --font-weight-bold: 700;
    --line-height-body: 1.85;
    --line-height-heading: 1.25;
    --letter-spacing-eyebrow: .22em;
    --space-1: .25rem;
    --space-2: .5rem;
    --space-3: .75rem;
    --space-4: 1rem;
    --space-5: 1.5rem;
    --space-6: 2rem;
    --space-7: 3rem;
    --space-8: 4rem;
    --space-9: 6rem;
    --section-space: clamp(4rem, 2.2rem + 4vw, 7.5rem);
    --section-space-small: clamp(3rem, 2rem + 2vw, 4.75rem);
    --container-width: 80rem;
    --container-width-narrow: 69rem;
    --container-gutter: clamp(1.25rem, 4vw, 3.25rem);
    --radius-button: .25rem;
    --radius-card: .45rem;
    --radius-pill: 999px;
    --shadow-soft: 0 1.25rem 3rem rgb(7 42 69 / 9%);
    --shadow-card: 0 .7rem 2.4rem rgb(7 42 69 / 6%);
    --header-height: 5.35rem;
    --header-height-mobile: 4.4rem;
    --tap-target: 2.75rem;
    --transition-fast: 180ms ease;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--color-surface); color: var(--color-text); font-family: var(--font-body); font-size: var(--font-size-body); line-height: var(--line-height-body); }
h1, h2, h3, p, ul { margin: 0; }
h1, h2, h3 { color: var(--color-primary); font-family: var(--font-display); font-weight: 700; letter-spacing: .025em; line-height: var(--line-height-heading); }
h3 { font-size: var(--font-size-card); }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; }
img { display: block; max-width: 100%; height: auto; }
svg { display: block; }
ul { padding: 0; list-style: none; }
:where(a, button):focus-visible { outline: 3px solid var(--color-focus); outline-offset: 4px; }
:where(h1, h2, h3, p, a) { overflow-wrap: anywhere; }
[tabindex="-1"]:focus { outline: none; }

.container { width: 100%; max-width: calc(var(--container-width) + var(--container-gutter) * 2); padding-inline: var(--container-gutter); margin-inline: auto; }
.container--narrow { max-width: calc(var(--container-width-narrow) + var(--container-gutter) * 2); }
.section { position: relative; padding-block: var(--section-space); }
.section--muted { background-color: var(--color-background); background-image: linear-gradient(rgb(18 59 93 / 2.5%) 1px, transparent 1px), linear-gradient(90deg, rgb(18 59 93 / 2.5%) 1px, transparent 1px); background-size: 3rem 3rem; }
.icon { width: 1.25rem; height: 1.25rem; flex: 0 0 auto; }
.skip-link { position: fixed; z-index: 100; top: .75rem; left: 1rem; padding: .65rem 1rem; color: #fff; background: var(--color-primary); transform: translateY(-180%); }
.skip-link:focus { transform: translateY(0); }
.eyebrow { color: var(--color-text-link); font-size: .75rem; font-weight: 700; letter-spacing: var(--letter-spacing-eyebrow); line-height: 1.5; text-transform: uppercase; }

.site-header { position: sticky; z-index: 50; top: 0; background: rgb(255 255 255 / 96%); border-bottom: 1px solid rgb(18 59 93 / 10%); backdrop-filter: blur(1rem); }
.site-header__inner { min-height: var(--header-height); display: flex; align-items: center; gap: clamp(1rem, 2vw, 2rem); }
.site-brand { flex: 0 0 auto; min-width: 0; }
.brand { display: inline-flex; align-items: center; gap: .8rem; max-width: 100%; }
.brand__mark { display: grid; width: 2.55rem; height: 2.55rem; place-items: center; flex: 0 0 auto; border-radius: .35rem; color: #fff; background: var(--color-primary-dark); box-shadow: inset 0 0 0 1px rgb(255 255 255 / 15%); }
.brand__mark svg { width: 1.5rem; height: 1.5rem; stroke: currentColor; stroke-width: 1.45; stroke-linecap: round; stroke-linejoin: round; }
.brand__logo { width: 2.75rem; height: 2.75rem; object-fit: contain; flex: 0 0 auto; }
.brand__text { min-width: 0; }
.brand__name { display: block; color: var(--color-primary-dark); font-family: var(--font-display); font-size: 1.16rem; font-weight: 700; letter-spacing: .06em; line-height: 1.25; }
.brand__english { display: block; margin-top: .15rem; color: var(--color-secondary); font-size: .54rem; font-weight: 700; letter-spacing: .2em; line-height: 1.4; white-space: nowrap; }
.site-nav { margin-inline: auto; }
.site-nav__list { display: flex; align-items: center; gap: clamp(.75rem, 1.5vw, 1.8rem); }
.site-nav__link { position: relative; display: inline-flex; align-items: center; min-height: var(--tap-target); color: #344b5b; white-space: nowrap; font-size: .9rem; font-weight: 600; }
.site-nav__link::after { content: ""; position: absolute; right: 50%; bottom: .1rem; left: 50%; height: 2px; background: var(--color-accent); transition: right var(--transition-fast), left var(--transition-fast); }
.site-nav__link:hover, .site-nav__link[aria-current="page"] { color: var(--color-text-link); }
.site-nav__link:hover::after, .site-nav__link[aria-current="page"]::after { right: 0; left: 0; }
.desktop-actions { display: flex; align-items: center; gap: 1rem; flex-shrink: 0; }
.header-phone { display: inline-flex; align-items: center; gap: .45rem; min-height: var(--tap-target); color: var(--color-primary); font-size: .82rem; font-weight: 700; }
.header-phone:hover { color: var(--color-accent); }
.mobile-actions { display: none; }
.icon-button { display: inline-flex; align-items: center; justify-content: center; width: var(--tap-target); height: var(--tap-target); border: 1px solid var(--color-border); border-radius: var(--radius-card); color: var(--color-primary); background: #fff; }
.icon-button .icon { width: 1.45rem; height: 1.45rem; }
.icon-button--phone { color: #fff; border-color: var(--color-accent); background: var(--color-accent); }
.menu-toggle { display: none; }
.menu-toggle__close { display: none; }
.menu-toggle[aria-expanded="true"] .menu-toggle__open { display: none; }
.menu-toggle[aria-expanded="true"] .menu-toggle__close { display: block; }

.button { display: inline-flex; justify-content: center; align-items: center; gap: .55rem; min-height: 3.15rem; padding: .75rem 1.45rem; border: 1px solid transparent; border-radius: var(--radius-button); font-size: .9rem; font-weight: 700; letter-spacing: .02em; line-height: 1.4; text-align: center; transition: transform var(--transition-fast), background var(--transition-fast), color var(--transition-fast), border-color var(--transition-fast), box-shadow var(--transition-fast); }
.button:hover { transform: translateY(-2px); }
.button--primary { color: #fff; background: var(--color-accent); border-color: var(--color-accent); box-shadow: 0 .75rem 1.8rem rgb(244 122 42 / 22%); }
.button--primary:hover { background: #dc651b; border-color: #dc651b; box-shadow: 0 1rem 2rem rgb(244 122 42 / 28%); }
.button--outline { color: var(--color-primary); border-color: rgb(18 59 93 / 40%); background: transparent; }
.button--outline:hover { color: #fff; background: var(--color-primary); border-color: var(--color-primary); }
.button-row { display: flex; flex-wrap: wrap; align-items: center; gap: .85rem; margin-top: 2rem; }
.text-link { display: inline-flex; align-items: center; gap: .5rem; min-height: var(--tap-target); margin-top: .75rem; color: var(--color-text-link); font-size: .88rem; font-weight: 700; }
.text-link::after { content: ""; width: 1.75rem; height: 1px; background: currentColor; transition: width var(--transition-fast); }
.text-link:hover::after { width: 2.5rem; }

.page-hero { position: relative; isolation: isolate; overflow: hidden; color: #fff; background: var(--color-primary-dark); }
.page-hero__image, .cta__image { position: absolute; inset: 0; z-index: -3; width: 100%; height: 100%; object-fit: cover; object-position: center; }
.page-hero::before { content: ""; position: absolute; inset: 0; z-index: -2; background: linear-gradient(90deg, rgb(6 35 57 / 96%) 0%, rgb(8 42 69 / 87%) 38%, rgb(8 42 69 / 37%) 72%, rgb(244 122 42 / 18%) 100%); }
.page-hero::after { content: ""; position: absolute; inset: 0; z-index: -1; pointer-events: none; background: radial-gradient(circle at 78% 92%, rgb(244 122 42 / 34%), transparent 29%), linear-gradient(90deg, transparent 0 7%, rgb(255 255 255 / 7%) 7% 7.08%, transparent 7.08% 100%); }
.page-hero__content { min-height: 20rem; display: flex; flex-direction: column; justify-content: center; padding-block: 4.5rem; }
.page-hero--large .page-hero__content { min-height: clamp(34rem, 68vh, 43rem); padding-block: 7rem; }
.page-hero .eyebrow { margin-bottom: .9rem; color: var(--color-accent-light); }
.page-hero__title { max-width: 48rem; color: #fff; font-size: var(--font-size-heading); text-shadow: 0 .15rem 1.2rem rgb(0 0 0 / 12%); }
.page-hero--large .page-hero__title { max-width: 54rem; font-size: var(--font-size-hero); }
.page-hero__subtitle { max-width: 44rem; margin-top: 1rem; color: rgb(255 255 255 / 82%); line-height: 1.95; }
.page-hero--large .page-hero__subtitle { max-width: 40rem; font-size: 1.08rem; }
.page-hero__content > * { animation: hero-rise .65s ease both; }
.page-hero__content > :nth-child(2) { animation-delay: .08s; }
.page-hero__content > :nth-child(3) { animation-delay: .16s; }
.page-hero__content > :nth-child(4) { animation-delay: .24s; }
@keyframes hero-rise { from { opacity: 0; transform: translateY(1rem); } to { opacity: 1; transform: none; } }
.page-hero__image { animation: hero-image-in 1.4s cubic-bezier(.2, .75, .2, 1) both; }
@keyframes hero-image-in { from { opacity: .55; transform: scale(1.055); } to { opacity: 1; transform: scale(1); } }
.page-hero__rail { position: absolute; z-index: 3; right: 0; bottom: 0; width: clamp(5rem, 14vw, 12rem); height: .28rem; background: linear-gradient(90deg, transparent, var(--color-accent)); transform-origin: right; animation: rail-in 1.1s .35s cubic-bezier(.2, .75, .2, 1) both; }
@keyframes rail-in { from { transform: scaleX(0); } to { transform: scaleX(1); } }
.page-hero :focus-visible, .cta :focus-visible, .site-footer :focus-visible { outline-color: var(--color-accent-light); }
.section-heading { margin-bottom: 2rem; }
.section-heading--centered { text-align: center; }
.section-heading__mark { display: inline-flex; align-items: center; justify-content: center; width: 2.35rem; height: 2.35rem; margin-bottom: .9rem; border: 1px solid rgb(31 103 154 / 24%); border-radius: 50%; color: var(--color-secondary); background: rgb(255 255 255 / 62%); }
.section-heading__mark .icon { width: 1.05rem; height: 1.05rem; }
.section-heading--centered .section-heading__mark { margin-inline: auto; }
.section-heading .eyebrow { margin-bottom: .65rem; }
.section-heading__title { font-size: var(--font-size-heading); }
.section-heading__description { max-width: 45rem; margin-top: .85rem; color: var(--color-muted); }
.section-heading--centered .section-heading__description { margin-inline: auto; }

.preview-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.5rem; }
.card { min-width: 0; overflow: hidden; border: 1px solid var(--color-border); border-radius: var(--radius-card); background: #fff; box-shadow: var(--shadow-card); transition: transform var(--transition-fast), border-color var(--transition-fast), box-shadow var(--transition-fast); }
.card--interactive:hover { transform: translateY(-.3rem); border-color: rgb(31 103 154 / 42%); box-shadow: var(--shadow-soft); }
.card__image { aspect-ratio: 16 / 9; overflow: hidden; }
.card__image img { width: 100%; height: 100%; object-fit: cover; transition: transform .55s ease; }
.card:hover .card__image img { transform: scale(1.035); }
.card__content { padding: clamp(1.25rem, 1rem + 1vw, 2rem); }
.card__content > p:not(.eyebrow) { margin-top: 1rem; color: var(--color-muted); }
.development-note { width: fit-content; max-width: 100%; margin-bottom: 1.5rem; color: var(--color-muted); font-size: .78rem; }

.cta { position: relative; isolation: isolate; overflow: hidden; padding-block: var(--section-space-small); color: #fff; background: var(--color-primary); text-align: center; }
.cta::before { content: ""; position: absolute; inset: 0; z-index: -2; background: linear-gradient(90deg, rgb(5 30 50 / 94%), rgb(10 46 75 / 83%), rgb(244 122 42 / 22%)); }
.cta::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(90deg, transparent 0 12%, rgb(255 255 255 / 7%) 12% 12.08%, transparent 12.08%); }
.cta__title { color: #fff; font-size: var(--font-size-heading); }
.cta__subtitle { margin-top: .6rem; color: rgb(255 255 255 / 76%); }
.cta .button { margin-top: 1.5rem; }

.contact-rail { position: fixed; z-index: 45; top: 52%; right: max(.65rem, env(safe-area-inset-right)); display: grid; gap: .55rem; transform: translateY(-50%); }
.contact-rail__item { position: relative; display: grid; place-items: center; width: 3.35rem; height: 3.35rem; padding: 0; border: 2px solid rgb(255 255 255 / 90%); border-radius: 50%; color: #fff; box-shadow: 0 .65rem 1.8rem rgb(4 29 48 / 20%); transition: transform var(--transition-fast), opacity var(--transition-fast), background var(--transition-fast); }
.contact-rail__item:hover { color: #fff; transform: translateX(-.2rem) scale(1.045); }
.contact-rail__item:focus-visible { outline: 3px solid var(--color-accent-light); outline-offset: 3px; }
.contact-rail__item--line { background: #06c755; }
.contact-rail__item--line svg { width: 2.55rem; height: 2.55rem; }
.contact-rail__item--line path { fill: #fff; }
.contact-rail__item--line text { fill: #06a847; font-family: Arial, sans-serif; font-size: 6.5px; font-weight: 900; letter-spacing: -.2px; }
.contact-rail__item--phone { background: linear-gradient(145deg, #b655ef, #7747e8); }
.contact-rail__item--phone .icon { width: 1.45rem; height: 1.45rem; stroke-width: 2; }
.contact-rail__back-to-top { border-color: rgb(255 255 255 / 82%); background: var(--color-primary); font-size: 1.45rem; cursor: pointer; opacity: 0; pointer-events: none; transform: translateY(.65rem) scale(.82); }
.contact-rail__back-to-top.is-visible { opacity: 1; pointer-events: auto; transform: none; }
.contact-rail__back-to-top:hover { background: var(--color-accent); transform: translateX(-.2rem) scale(1.045); }

.site-footer { min-height: 27rem; padding-top: var(--section-space-small); color: var(--color-footer-muted); background-color: var(--color-primary-dark); background-image: linear-gradient(rgb(255 255 255 / 2.5%) 1px, transparent 1px), linear-gradient(90deg, rgb(255 255 255 / 2.5%) 1px, transparent 1px); background-size: 3.5rem 3.5rem; }
.site-footer__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 2.5rem; padding-bottom: 4rem; }
.site-footer__grid--with-brand { grid-template-columns: 1.35fr .7fr 1.15fr 1fr; }
.brand--footer .brand__mark { background: rgb(255 255 255 / 8%); border: 1px solid rgb(255 255 255 / 14%); }
.brand--footer .brand__name { color: #fff; }
.brand--footer .brand__english { color: var(--color-footer-muted); }
.site-footer__intro { max-width: 21rem; margin-top: 1.3rem; font-size: .82rem; line-height: 1.9; }
.site-footer__heading { margin-bottom: 1rem; color: #fff; font-family: var(--font-body); font-size: .95rem; letter-spacing: .08em; }
.footer-nav { display: grid; gap: .2rem; }
.footer-nav--services { grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: 1rem; }
.footer-nav a { display: inline-flex; align-items: center; min-height: 2rem; font-size: .8rem; }
.site-footer a:hover { color: #fff; }
.footer-phone { display: inline-flex; align-items: center; min-height: var(--tap-target); gap: .6rem; color: #fff; font-size: 1.05rem; }
.footer-email { display: flex; align-items: center; gap: .6rem; width: fit-content; max-width: 100%; min-height: 2.25rem; color: var(--color-footer-muted); font-size: .8rem; overflow-wrap: anywhere; }
.footer-email .icon { flex: 0 0 auto; width: 1rem; height: 1rem; color: var(--color-accent-light); }
.site-footer__contact p { margin-top: .55rem; font-size: .8rem; }
.site-footer__bottom { display: flex; justify-content: space-between; gap: 1rem; border-top: 1px solid rgb(180 201 216 / 18%); padding-block: 1.5rem; font-size: .72rem; }
.development-indicator { color: var(--color-footer-muted); }

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