/* Data Sense Ltd 有數科技 — shared stylesheet
   Pure static, system font stack, no external dependencies */

:root {
  --ink: #0d1526;
  --ink-soft: #3c4a63;
  --ink-mute: #66738c;
  --bg: #f7f9fc;
  --bg-raised: #ffffff;
  --line: #e4e9f2;
  --brand: #1a56db;
  --brand-deep: #0f3aa0;
  --brand-cyan: #06b6d4;
  --hero-grad-a: #0a1128;
  --hero-grad-b: #10264f;
  --hero-grad-c: #123a6e;
  --radius: 14px;
  --shadow-sm: 0 1px 2px rgba(13, 21, 38, 0.06), 0 2px 8px rgba(13, 21, 38, 0.05);
  --shadow-md: 0 6px 24px rgba(13, 21, 38, 0.10);
  --maxw: 1120px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, "PingFang HK", "PingFang TC", "Microsoft JhengHei",
    "Noto Sans CJK TC", sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img, svg { display: block; max-width: 100%; }

a { color: var(--brand); text-decoration: none; }
a:hover { color: var(--brand-deep); }

.container {
  width: 100%;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: saturate(1.4) blur(12px);
  -webkit-backdrop-filter: saturate(1.4) blur(12px);
  border-bottom: 1px solid var(--line);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 64px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.12rem;
  color: var(--ink);
  letter-spacing: 0.01em;
  white-space: nowrap;
}
.brand:hover { color: var(--ink); }

.brand-mark {
  width: 30px;
  height: 30px;
  flex: 0 0 auto;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 22px;
  font-size: 0.95rem;
}

.site-nav a {
  color: var(--ink-soft);
  font-weight: 500;
}
.site-nav a:hover { color: var(--brand); }

.lang-switch {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-left: 6px;
  padding: 6px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--bg-raised);
  font-weight: 600;
  font-size: 0.88rem;
  color: var(--ink) !important;
  box-shadow: var(--shadow-sm);
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.lang-switch:hover {
  border-color: var(--brand);
  box-shadow: var(--shadow-md);
}
.lang-switch svg { width: 15px; height: 15px; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  color: #eef3ff;
  background:
    radial-gradient(1100px 500px at 85% -10%, rgba(6, 182, 212, 0.28), transparent 60%),
    radial-gradient(900px 520px at 8% 110%, rgba(26, 86, 219, 0.35), transparent 55%),
    linear-gradient(135deg, var(--hero-grad-a) 0%, var(--hero-grad-b) 55%, var(--hero-grad-c) 100%);
  overflow: hidden;
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.045) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: radial-gradient(ellipse 80% 70% at 50% 40%, #000 30%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 80% 70% at 50% 40%, #000 30%, transparent 75%);
  pointer-events: none;
}

.hero-inner {
  position: relative;
  z-index: 1;
  padding: 108px 24px 116px;
  text-align: center;
}

.hero-eyebrow {
  display: inline-block;
  margin: 0 0 18px;
  padding: 6px 16px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.07);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #a9c6ff;
}

.hero h1 {
  margin: 0 0 8px;
  font-size: clamp(2.4rem, 6vw, 4rem);
  line-height: 1.1;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #ffffff;
}

.hero .hero-name-zh {
  display: block;
  margin-top: 6px;
  font-size: clamp(1.3rem, 3vw, 1.9rem);
  font-weight: 600;
  color: #9fd8e8;
  letter-spacing: 0.12em;
}

.hero .tagline {
  max-width: 640px;
  margin: 22px auto 0;
  font-size: clamp(1.05rem, 2.2vw, 1.28rem);
  line-height: 1.6;
  color: #c6d6f5;
}

.hero-cta {
  margin-top: 40px;
  display: flex;
  justify-content: center;
  gap: 14px;
  flex-wrap: wrap;
}

.btn {
  display: inline-block;
  padding: 13px 30px;
  border-radius: 10px;
  font-weight: 600;
  font-size: 1rem;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}
.btn:hover { transform: translateY(-1px); }

.btn-primary {
  background: linear-gradient(135deg, var(--brand) 0%, #3b7bfd 100%);
  color: #ffffff !important;
  box-shadow: 0 8px 22px rgba(26, 86, 219, 0.42);
}
.btn-primary:hover { box-shadow: 0 12px 28px rgba(26, 86, 219, 0.52); color: #ffffff; }

.btn-ghost {
  border: 1px solid rgba(255, 255, 255, 0.32);
  color: #eaf1ff !important;
  background: rgba(255, 255, 255, 0.06);
}
.btn-ghost:hover { background: rgba(255, 255, 255, 0.13); color: #ffffff; }

/* ---------- Sections ---------- */
.section { padding: 88px 0; }
.section-alt { background: var(--bg-raised); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }

.section-head {
  max-width: 680px;
  margin: 0 auto 52px;
  text-align: center;
}

.section-kicker {
  margin: 0 0 10px;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--brand);
}

.section-title {
  margin: 0;
  font-size: clamp(1.7rem, 3.6vw, 2.3rem);
  font-weight: 800;
  letter-spacing: -0.015em;
  line-height: 1.2;
}

.section-lead {
  margin: 16px 0 0;
  color: var(--ink-mute);
  font-size: 1.06rem;
}

/* About */
.about-grid {
  display: grid;
  grid-template-columns: 1.25fr 1fr;
  gap: 48px;
  align-items: center;
}

.about-copy p { margin: 0 0 1.1em; color: var(--ink-soft); font-size: 1.05rem; }
.about-copy p:last-child { margin-bottom: 0; }

.about-facts {
  list-style: none;
  margin: 0;
  padding: 28px 30px;
  background: var(--bg-raised);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}

.section-alt .about-facts { background: var(--bg); }

.about-facts li {
  display: flex;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
  font-size: 0.98rem;
}
.about-facts li:last-child { border-bottom: 0; }
.about-facts .fact-label {
  flex: 0 0 auto;
  min-width: 118px;
  font-weight: 700;
  color: var(--ink);
}
.about-facts .fact-value { color: var(--ink-soft); }

/* Cards */
.cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.card {
  padding: 32px 28px;
  background: var(--bg-raised);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}
.card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: #cdd9ef;
}

.card-icon {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  margin-bottom: 20px;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(26, 86, 219, 0.12), rgba(6, 182, 212, 0.14));
  color: var(--brand);
}
.card-icon svg { width: 24px; height: 24px; }

.card h3 {
  margin: 0 0 10px;
  font-size: 1.16rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

.card p {
  margin: 0;
  color: var(--ink-mute);
  font-size: 0.97rem;
}

/* Headquarters */
.hq-wrap {
  display: grid;
  grid-template-columns: 1fr 1.1fr;
  gap: 48px;
  align-items: center;
}

.hq-badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 18px;
  padding: 8px 18px;
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(26, 86, 219, 0.10), rgba(6, 182, 212, 0.12));
  color: var(--brand-deep);
  font-weight: 700;
  font-size: 0.95rem;
}
.hq-badge svg { width: 17px; height: 17px; }

.hq-copy p { margin: 0 0 1em; color: var(--ink-soft); font-size: 1.05rem; }
.hq-copy p:last-child { margin-bottom: 0; }

.hq-panel {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  color: #eaf1ff;
  background:
    radial-gradient(600px 300px at 80% 0%, rgba(6, 182, 212, 0.30), transparent 60%),
    linear-gradient(150deg, #0c1730 0%, #12325f 100%);
  box-shadow: var(--shadow-md);
  padding: 40px 36px;
}

.hq-panel .hq-city {
  margin: 0 0 4px;
  font-size: 1.7rem;
  font-weight: 800;
  letter-spacing: -0.01em;
  color: #ffffff;
}
.hq-panel .hq-city-zh {
  margin: 0 0 18px;
  font-size: 1.05rem;
  color: #9fd8e8;
  letter-spacing: 0.1em;
}
.hq-panel .hq-note {
  margin: 0;
  color: #bccdf0;
  font-size: 0.96rem;
  max-width: 40ch;
}

/* Contact */
.contact-box {
  max-width: 720px;
  margin: 0 auto;
  text-align: center;
  padding: 48px 36px;
  background: var(--bg-raised);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}

.contact-box p { color: var(--ink-soft); margin: 0 0 22px; font-size: 1.04rem; }

.contact-email {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 28px;
  border-radius: 10px;
  background: var(--bg);
  border: 1px solid var(--line);
  font-weight: 700;
  font-size: 1.08rem;
  color: var(--ink) !important;
}
.contact-email:hover { border-color: var(--brand); color: var(--brand) !important; }
.contact-email svg { width: 18px; height: 18px; color: var(--brand); }

/* ---------- Footer ---------- */
.site-footer {
  padding: 40px 0 48px;
  background: var(--ink);
  color: #97a3bd;
  font-size: 0.92rem;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #dfe7f7;
  font-weight: 700;
}
.footer-brand .brand-mark { width: 24px; height: 24px; }

.footer-nav { display: flex; gap: 20px; }
.footer-nav a { color: #97a3bd; }
.footer-nav a:hover { color: #ffffff; }

.footer-copy { width: 100%; margin: 18px 0 0; padding-top: 18px; border-top: 1px solid rgba(255,255,255,0.09); }

/* ---------- Responsive ---------- */
@media (max-width: 880px) {
  .about-grid, .hq-wrap { grid-template-columns: 1fr; gap: 32px; }
  .cards { grid-template-columns: 1fr; }
  .hero-inner { padding: 80px 24px 88px; }
  .section { padding: 64px 0; }
  .site-nav { gap: 14px; font-size: 0.9rem; }
  .site-nav a:not(.lang-switch) { display: none; }
}

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