:root {
  --brand: #1479b5;
  --brand-dark: #0e5f91;
  --ink: #17202e;
  --muted: #5b6678;
  --line: #e4e8ef;
  --bg: #ffffff;
  --bg-soft: #f5f7fb;
  --radius: 14px;
  --shadow: 0 6px 24px rgba(23, 32, 46, .08);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Noto Sans TC", "PingFang TC", "Microsoft JhengHei", sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--brand); text-decoration: none; }
a:hover { color: var(--brand-dark); }
h1, h2, h3 { line-height: 1.3; margin: 0 0 .6em; }
h1 { font-size: clamp(2rem, 5vw, 3.2rem); }
h2 { font-size: clamp(1.5rem, 3.4vw, 2.1rem); }
h3 { font-size: 1.2rem; }
p { margin: 0 0 1em; }

.container { width: min(1120px, 100% - 40px); margin-inline: auto; }
.skip { position: absolute; left: -999px; }
.skip:focus { left: 12px; top: 12px; background: #fff; padding: 8px 12px; z-index: 100; }

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255, 255, 255, .92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.brand { font-weight: 800; font-size: 1.25rem; color: var(--ink); letter-spacing: .02em; }
.site-nav { display: flex; gap: 28px; }
.site-nav a { color: var(--ink); font-weight: 500; padding: 6px 0; border-bottom: 2px solid transparent; }
.site-nav a:hover, .site-nav a.active { color: var(--brand); border-color: var(--brand); }
.nav-toggle { display: none; background: none; border: 0; padding: 8px; cursor: pointer; }
.nav-toggle span { display: block; width: 24px; height: 2px; background: var(--ink); margin: 5px 0; }

/* Buttons */
.btn {
  display: inline-block; padding: 12px 28px; border-radius: 999px;
  background: var(--brand); color: #fff; font-weight: 600; border: 0; cursor: pointer; font-size: 1rem;
  transition: background .2s, transform .2s;
}
.btn:hover { background: var(--brand-dark); color: #fff; transform: translateY(-1px); }
.btn.ghost { background: transparent; color: var(--brand); border: 1.5px solid var(--brand); }
.btn.ghost:hover { background: var(--brand); color: #fff; }

/* Sections */
.section { padding: 80px 0; }
.section.soft { background: var(--bg-soft); }
.section-head { max-width: 640px; margin-bottom: 40px; }
.section-head p { color: var(--muted); }
.eyebrow { color: var(--brand); font-weight: 700; letter-spacing: .12em; font-size: .85rem; text-transform: uppercase; }

/* Hero */
.hero { padding: 96px 0 88px; background: linear-gradient(160deg, #eef8fd 0%, #ffffff 60%); }
.hero-inner { display: grid; grid-template-columns: 1.1fr .9fr; gap: 48px; align-items: center; }
.hero p.lead { font-size: 1.15rem; color: var(--muted); max-width: 34em; }
.hero-actions { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 28px; }
.hero-visual {
  aspect-ratio: 4 / 3; border-radius: 24px; box-shadow: var(--shadow);
  background: linear-gradient(135deg, var(--brand) 0%, #28a7e1 100%);
  display: grid; place-items: center; color: #fff; font-weight: 700; font-size: 1.1rem; letter-spacing: .1em;
}

/* Cards */
.grid { display: grid; gap: 24px; }
.grid.cols-3 { grid-template-columns: repeat(3, 1fr); }
.grid.cols-2 { grid-template-columns: repeat(2, 1fr); }
.card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 28px; transition: box-shadow .2s, transform .2s;
}
.card:hover { box-shadow: var(--shadow); transform: translateY(-3px); }
.card .icon {
  width: 48px; height: 48px; border-radius: 12px; background: #def1fa; color: var(--brand);
  display: grid; place-items: center; font-size: 1.4rem; margin-bottom: 16px;
}
.card p { color: var(--muted); margin: 0; }

/* Stats */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; text-align: center; }
.stats strong { display: block; font-size: 2.4rem; color: var(--brand); line-height: 1.2; }
.stats span { color: var(--muted); }

/* Page banner */
.page-banner { padding: 64px 0 48px; background: var(--bg-soft); border-bottom: 1px solid var(--line); }
.page-banner p { color: var(--muted); max-width: 40em; margin: 0; }

/* About */
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
.placeholder-img {
  aspect-ratio: 4 / 3; border-radius: var(--radius); background: #dfe6f5; color: #7a8aa8;
  display: grid; place-items: center; font-weight: 600;
}
.timeline { list-style: none; margin: 0; padding: 0 0 0 20px; border-left: 2px solid var(--line); }
.timeline li { position: relative; padding: 0 0 28px 24px; }
.timeline li::before {
  content: ""; position: absolute; left: -29px; top: 8px; width: 12px; height: 12px;
  border-radius: 50%; background: var(--brand); box-shadow: 0 0 0 4px #def1fa;
}
.timeline b { color: var(--brand); display: block; }
.team { text-align: center; }
.team .avatar {
  width: 96px; height: 96px; border-radius: 50%; background: #dfe6f5; margin: 0 auto 14px;
  display: grid; place-items: center; font-size: 2rem; color: #7a8aa8;
}
.team small { color: var(--muted); }

/* Services */
.service-list { display: grid; gap: 20px; }
.service-item { display: grid; grid-template-columns: 64px 1fr; gap: 20px; align-items: start; }
.service-item ul { margin: 10px 0 0; padding-left: 1.2em; color: var(--muted); }
.steps { counter-reset: step; display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; list-style: none; padding: 0; margin: 0; }
.steps li { counter-increment: step; }
.steps li::before {
  content: counter(step); display: grid; place-items: center; width: 40px; height: 40px;
  border-radius: 50%; background: var(--brand); color: #fff; font-weight: 700; margin-bottom: 12px;
}
.steps p { color: var(--muted); margin: 0; }

/* FAQ */
details { border-bottom: 1px solid var(--line); padding: 16px 0; }
summary { cursor: pointer; font-weight: 600; }
details p { margin: 10px 0 0; color: var(--muted); }

/* CTA */
.cta { background: var(--brand); color: #fff; text-align: center; padding: 72px 0; }
.cta p { opacity: .9; }
.cta .btn { background: #fff; color: var(--brand); }
.cta .btn:hover { background: #eef8fd; }

/* Contact */
.contact-layout { display: grid; grid-template-columns: 1.2fr .8fr; gap: 48px; }
.form-row { margin-bottom: 18px; }
label { display: block; font-weight: 600; margin-bottom: 6px; }
input[type=text], input[type=email], input[type=tel], textarea, select {
  width: 100%; padding: 12px 14px; border: 1.5px solid var(--line); border-radius: 10px;
  font: inherit; background: #fff; transition: border-color .2s, box-shadow .2s;
}
input:focus, textarea:focus, select:focus {
  outline: none; border-color: var(--brand); box-shadow: 0 0 0 4px rgba(40, 167, 225, .2);
}
textarea { min-height: 150px; resize: vertical; }
.hp { position: absolute; left: -9999px; }
.alert { padding: 14px 18px; border-radius: 10px; margin-bottom: 20px; }
.alert.ok { background: #e7f7ee; color: #14633a; }
.alert.err { background: #fdecec; color: #8a1f1f; }
.alert ul { margin: 0; padding-left: 1.2em; }
.info-list { list-style: none; padding: 0; margin: 0; }
.info-list li { padding: 14px 0; border-bottom: 1px solid var(--line); }
.info-list b { display: block; color: var(--muted); font-size: .85rem; font-weight: 600; }

/* Footer */
.site-footer { background: #0f1724; color: #b9c2d3; padding-top: 56px; }
.site-footer strong { color: #fff; display: block; margin-bottom: 10px; }
.site-footer a { color: #b9c2d3; }
.site-footer a:hover { color: #fff; }
.footer-grid { display: grid; grid-template-columns: 1.3fr 1.3fr 1fr; gap: 40px; padding-bottom: 40px; }
.copyright { border-top: 1px solid #243047; padding: 20px 0; font-size: .9rem; }

/* Dropdown */
.has-sub { position: relative; }
.has-sub > a { display: inline-block; }
.sub {
  display: none; position: absolute; left: -12px; top: 100%; min-width: 200px;
  background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow); padding: 8px;
}
.has-sub:hover .sub, .has-sub:focus-within .sub { display: block; }
.sub a { display: block; padding: 10px 14px; border: 0; border-radius: 8px; white-space: nowrap; }
.sub a:hover { background: var(--bg-soft); }

/* Philosophy */
.philo { display: grid; grid-template-columns: .9fr 1.1fr; gap: 48px; align-items: center; }
.philo svg { width: 100%; height: auto; }
.philo .legend { list-style: none; padding: 0; margin: 20px 0 0; }
.philo .legend li { padding: 10px 0; border-bottom: 1px solid var(--line); color: var(--muted); }
.philo .legend b { color: var(--ink); }

/* Service detail */
.detail-layout { display: grid; grid-template-columns: 1fr 300px; gap: 48px; align-items: start; }
.side-card { background: var(--bg-soft); border-radius: var(--radius); padding: 24px; position: sticky; top: 92px; }
.side-card a.item { display: block; padding: 10px 0; border-bottom: 1px solid var(--line); color: var(--ink); }
.side-card a.item:hover, .side-card a.item.on { color: var(--brand); font-weight: 600; }
.check-list { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 10px 24px; }
.check-list li { padding-left: 1.6em; position: relative; }
.check-list li::before { content: "✓"; position: absolute; left: 0; color: var(--brand); font-weight: 700; }
.tag { display: inline-block; font-size: .8rem; padding: 2px 10px; border-radius: 999px; background: #def1fa; color: var(--brand); margin: 0 6px 6px 0; }

/* Partners */
.logo-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.logo-box {
  aspect-ratio: 3 / 2; border: 1px dashed #c5cde0; border-radius: var(--radius);
  display: grid; place-items: center; color: #8793ab; font-weight: 600; background: #fff;
}

/* Social */
.social { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 20px; }
.qr { width: 160px; height: 160px; border-radius: 12px; border: 1px solid var(--line); object-fit: contain; background: #fff; }
.qr-ph { width: 160px; height: 160px; border-radius: 12px; border: 1px dashed #c5cde0; display: grid; place-items: center; color: #8793ab; font-size: .85rem; text-align: center; }

/* Responsive */
@media (max-width: 860px) {
  .philo, .detail-layout { grid-template-columns: 1fr; }
  .side-card { position: static; }
  .logo-grid { grid-template-columns: repeat(2, 1fr); }
  .check-list { grid-template-columns: 1fr; }
  .has-sub > a { display: block; }
  .sub { display: block; position: static; border: 0; box-shadow: none; padding: 0 0 0 14px; }
  .sub a { padding: 12px 0; border-bottom: 1px solid var(--line); border-radius: 0; }
  .hero-inner, .two-col, .contact-layout { grid-template-columns: 1fr; }
  .grid.cols-3, .grid.cols-2, .stats, .steps, .footer-grid { grid-template-columns: 1fr 1fr; }
  .section { padding: 56px 0; }
  .nav-toggle { display: block; }
  .site-nav {
    display: none; position: absolute; left: 0; right: 0; top: 68px; background: #fff;
    flex-direction: column; gap: 0; border-bottom: 1px solid var(--line); padding: 8px 20px 16px;
  }
  .site-nav.open { display: flex; }
  .site-nav a { padding: 14px 0; border-bottom: 1px solid var(--line); }
}
@media (max-width: 560px) {
  .grid.cols-3, .grid.cols-2, .stats, .steps, .footer-grid { grid-template-columns: 1fr; }
}

.brand img { height: 44px; width: auto; }
