/* ================================================================
   SX Official Website — Warm Business Minimalism
   ToB SaaS + Agent · low-saturation warm neutrals (no AI-template blues)
   ================================================================ */

:root {
  color-scheme: light;

  /* Typography Scale (1.25 Major Third) */
  --text-xs:     0.8125rem;  /* 13px — 中文可读性优化 */
  --text-sm:     0.875rem;
  --text-base:   1rem;
  --text-lg:     1.25rem;
  --text-xl:     1.5rem;
  --text-2xl:    2rem;
  --text-3xl:    2.75rem;
  --text-4xl:    3.75rem;

  --lh-tight:   1.15;
  --lh-normal:  1.5;
  --lh-relaxed: 1.75;
  --lh-relaxed-zh: 1.75;

  --font-sans: 'PingFang SC', 'Noto Sans SC', 'Microsoft YaHei', 'Inter', -apple-system, 'Segoe UI', 'Helvetica Neue', sans-serif;

  /* Spacing (8px grid) */
  --space-xs:   4px;
  --space-sm:   8px;
  --space-md:   16px;
  --space-lg:   24px;
  --space-xl:   32px;
  --space-2xl:  48px;
  --space-3xl:  64px;
  --space-4xl:  96px;
  --space-5xl:  160px;

  /* Easing */
  --ease-expo:  cubic-bezier(0.16, 1, 0.3, 1);
  --ease-back:  cubic-bezier(0.34, 1.56, 0.64, 1);
  --ease-smooth:cubic-bezier(0.65, 0, 0.35, 1);

  /* Z-index layers */
  --z-base: 1;
  --z-overlay: 90;
  --z-nav: 100;
  --z-drawer-toggle: 101;
  --z-skip-link: 300;

  /* Layout */
  --max-width: 1280px;
  --content-narrow: 960px;
  --measure: 580px;            /* optimal reading width for lead text */
  --grid-gap: var(--space-md);
  --section-y: clamp(80px, 10vw, 140px);  /* responsive vertical rhythm */
  --card-pad: var(--space-lg);
  --card-pad-lg: var(--space-2xl);
  --nav-height: 64px;

  /* Focus ring */
  --focus-ring: 2px solid var(--accent);
  --focus-ring-offset: 4px;

  /* Radius (3 tiers + pill) */
  --radius-sm:   8px;
  --radius-md:   12px;
  --radius-lg:   16px;
  --radius-pill: 100px;
}

*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html {
  scroll-behavior: smooth;
  scroll-padding-top: var(--nav-height);
  font-size: 16px;
  -webkit-text-size-adjust: 100%;
}
body {
  font-family: var(--font-sans);
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: var(--lh-normal);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  font-weight: 400;
  overflow-x: hidden;
  transition: background 0.3s var(--ease-smooth), color 0.3s var(--ease-smooth);
}
::selection {
  background: var(--accent);
  color: var(--accent-on);
}

:lang(zh) .section-label,
:lang(zh) .contact-info-label {
  text-transform: none;
  letter-spacing: 0.04em;
}
:lang(zh) .section-lead,
:lang(zh) .hero-desc,
:lang(zh) .xiaohei-scenario-card p {
  line-height: var(--lh-relaxed-zh);
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }

.is-hidden { display: none !important; }
.sr-only {
  position: absolute; width: 1px; height: 1px;
  padding: 0; margin: -1px; overflow: hidden;
  clip: rect(0,0,0,0); border: 0;
}

.skip-link {
  position: absolute; top: -100%; left: var(--space-md); z-index: var(--z-skip-link);
  padding: 12px 24px; background: var(--accent); color: var(--accent-on);
  border-radius: var(--radius-sm); font-size: var(--text-sm); font-weight: 600;
}
.skip-link:focus { top: var(--space-md); }

/* Nav overlay (mobile drawer) */
.nav-overlay {
  position: fixed; inset: 0; z-index: var(--z-overlay);
  background: var(--overlay-bg);
  opacity: 0;
  transition: opacity 0.35s var(--ease-smooth);
  pointer-events: none;
}
.nav-overlay.is-visible {
  opacity: 1;
  pointer-events: auto;
}

.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: var(--z-nav);
  height: var(--nav-height);
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 var(--space-2xl);
  background: var(--nav-bg);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s var(--ease-smooth), background 0.3s var(--ease-smooth);
}
.nav.scrolled { border-bottom-color: var(--border); }
.nav-logo {
  font-size: var(--text-xl); font-weight: 700;
  letter-spacing: -0.02em; color: var(--text-primary);
}
.nav-logo img, .footer-logo img { display: block; width: auto; }
.nav-logo img { height: 54px; }
.footer-logo img { height: 44px; }
.nav-links { display: flex; align-items: center; gap: var(--space-lg); }
.nav-links a { font-size: var(--text-sm); color: var(--text-secondary); font-weight: 500; transition: color 0.2s var(--ease-smooth); border-radius: var(--radius-sm); }
.nav-links a:hover { color: var(--text-primary); }
.nav-links a.is-active { color: var(--accent); font-weight: 600; }
.nav-links a:focus-visible {
  outline: var(--focus-ring); outline-offset: var(--focus-ring-offset);
}
.nav-lang {
  display: flex; align-items: center; gap: var(--space-sm);
  font-size: var(--text-xs); font-weight: 600;
}
.nav-lang-sep { color: var(--text-tertiary); user-select: none; }
.nav-lang-link {
  color: var(--text-tertiary);
  padding: var(--space-xs) var(--space-sm);
  border-radius: var(--radius-sm);
}
.nav-lang-link:hover { color: var(--text-primary); }
.nav-lang-link.is-active {
  color: var(--accent);
  background: var(--accent-subtle);
}
.nav-cta {
  padding: var(--space-sm) var(--space-md); border: 1px solid var(--border); border-radius: var(--radius-sm);
  transition: border-color 0.2s var(--ease-smooth), background 0.2s var(--ease-smooth);
}
.nav-cta:hover {
  border-color: var(--text-tertiary);
  background: var(--accent-subtle);
}
.nav-cta.is-active {
  color: var(--accent);
  border-color: var(--accent);
  background: var(--accent-subtle);
  cursor: default;
}

.hamburger {
  display: none; flex-direction: column; justify-content: center; gap: 5px;
  width: 44px; height: 44px; background: none; border: none;
  cursor: pointer; padding: 10px; z-index: var(--z-drawer-toggle); border-radius: var(--radius-sm);
}
.hamburger:focus-visible { outline: var(--focus-ring); outline-offset: 2px; }
.hamburger span {
  display: block; width: 100%; height: 2px;
  background: var(--text-primary); border-radius: 1px;
  transition: transform 0.3s var(--ease-smooth), opacity 0.2s var(--ease-smooth);
}
.hamburger.active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.active span:nth-child(2) { opacity: 0; }
.hamburger.active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Hero */
.hero {
  min-height: 100vh; min-height: 100dvh;
  display: flex; align-items: center; justify-content: center;
  padding: calc(var(--nav-height) + var(--space-2xl)) var(--space-2xl) var(--space-2xl);
  text-align: center;
  background:
    radial-gradient(ellipse 75% 55% at 50% 38%, var(--accent-subtle) 0%, transparent 68%),
    radial-gradient(ellipse 50% 45% at 85% 15%, var(--sage-subtle) 0%, transparent 60%),
    var(--bg-primary);
}
.hero-content { max-width: 960px; margin: 0 auto; }
.hero-title {
  font-size: clamp(2rem, 5.5vw, var(--text-4xl)); font-weight: 700;
  letter-spacing: -0.03em; line-height: var(--lh-tight);
  color: var(--text-primary); margin-bottom: var(--space-2xl);
}
.hero-title em {
  font-style: normal;
  color: var(--accent);
  display: inline-block;
}
html[lang="en"] .hero-title {
  font-size: clamp(2rem, 5vw, 3.25rem);
  letter-spacing: -0.03em;
  word-break: keep-all;
  hyphens: auto;
}
html[lang="en"] .hero-manifesto span {
  letter-spacing: 0.04em;
}
.hero-desc {
  font-size: var(--text-lg); color: var(--text-secondary);
  max-width: 640px; margin: 0 auto var(--space-2xl);
  line-height: var(--lh-relaxed); font-weight: 400;
}
.hero-manifesto {
  display: flex; flex-wrap: wrap; justify-content: center; gap: var(--space-md);
  margin-bottom: var(--space-3xl);
}
.hero-manifesto span {
  font-size: var(--text-sm); color: var(--text-tertiary);
  padding: var(--space-sm) var(--space-md); border: 1px solid var(--border); border-radius: var(--radius-pill);
  font-weight: 500;
}
.scroll-hint {
  font-size: var(--text-xs); color: var(--text-tertiary);
  letter-spacing: 0.12em; text-transform: uppercase; font-weight: 500;
  margin-top: var(--space-3xl);
  display: flex; flex-direction: column; align-items: center; gap: 8px;
}
.scroll-hint-arrow {
  display: block; color: var(--text-tertiary); opacity: 0.6;
  animation: bounce-arrow 1.8s ease-in-out infinite;
}
@keyframes bounce-arrow {
  0%, 100% { transform: translateY(0); opacity: 0.35; }
  50% { transform: translateY(4px); opacity: 0.8; }
}

/* Sections */
.section {
  max-width: var(--max-width); margin: 0 auto;
  padding-left: var(--space-2xl); padding-right: var(--space-2xl);
}
.section-header {
  margin-bottom: var(--space-2xl);
  display: grid;
  grid-template-columns: minmax(100px, auto) 1fr;
  gap: var(--space-2xl);
  align-items: start;
  max-width: 1100px;
  margin-inline: auto;
}
.section-label {
  font-size: var(--text-xs); font-weight: 600; letter-spacing: 0.1em;
  text-transform: uppercase; color: var(--text-tertiary);
  padding-top: var(--space-sm);
  white-space: nowrap;
}
.section-heading {
  font-size: clamp(1.75rem, 3.5vw, 2.25rem); font-weight: 600;
  letter-spacing: -0.025em; line-height: var(--lh-tight);
  color: var(--text-primary); margin-bottom: var(--space-lg);
}
.section-lead {
  font-size: var(--text-base); line-height: var(--lh-relaxed);
  color: var(--text-secondary); max-width: var(--measure);
}
.about-page-section .section-lead {
  max-width: 680px;
}

.key-stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-xl);
  margin-top: var(--space-xl);
  padding-top: var(--space-xl); border-top: 1px solid var(--border);
  max-width: 1100px;
  margin-left: auto; margin-right: auto;
}
.stat-item { display: flex; flex-direction: column; padding: var(--space-md) 0; }
.stat-num {
  font-size: clamp(1.75rem, 4vw, 2.5rem); font-weight: 600;
  letter-spacing: -0.03em; color: var(--text-primary);
  line-height: 1; margin-bottom: var(--space-md);
  min-height: var(--text-2xl);
  display: flex; align-items: flex-end;
}
.stat-num--accent { color: var(--accent); }
.stat-num-text { font-size: var(--text-xl); font-weight: 600; }
.stat-label { font-size: var(--text-xs); color: var(--text-tertiary); font-weight: 500; }
.stat-desc {
  font-size: var(--text-xs); color: var(--text-tertiary);
  margin-top: var(--space-xs);
}

.products-diagram {
  width: 100%; max-width: var(--content-narrow); margin: 0 auto;
  display: block;
}
.products-diagram svg { width: 100%; height: auto; }
.pd-lines line {
  transition: stroke 0.3s var(--ease-smooth), stroke-width 0.3s var(--ease-smooth), opacity 0.3s var(--ease-smooth);
}
.pd-agent {
  transition: opacity 0.3s var(--ease-smooth);
}
.pd-agent rect {
  transition: fill 0.25s var(--ease-smooth), stroke 0.25s var(--ease-smooth), filter 0.25s var(--ease-smooth);
}
.pd-platform rect {
  transition: fill 0.25s var(--ease-smooth), stroke 0.25s var(--ease-smooth), filter 0.25s var(--ease-smooth);
}
@media (hover: hover) {
  .pd-agent:hover rect {
    fill: var(--bg-secondary);
    stroke: var(--accent);
    stroke-width: 1.5;
    filter: drop-shadow(0 2px 8px var(--accent-subtle));
  }
  .pd-platform:hover rect {
    fill: var(--bg-secondary);
    stroke: var(--accent);
    stroke-width: 1.5;
    filter: drop-shadow(0 2px 6px var(--accent-subtle));
  }
  .products-diagram:hover .pd-hub circle:first-child {
    r: 68;
    opacity: 0.18;
  }
}
.pd-hub circle {
  transition: r 0.3s var(--ease-back), opacity 0.3s var(--ease-smooth);
}

@media (max-width: 968px) {
  .xiaohei-scenario-grid { grid-template-columns: 1fr; }
}

/* Unified card base */
.card {
  background: var(--bg-tertiary);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: var(--card-pad);
  transition: border-color 0.25s var(--ease-smooth), box-shadow 0.25s var(--ease-smooth), transform 0.25s var(--ease-smooth);
}
@media (hover: hover) {
  .card:hover {
    border-color: var(--border-hover);
    box-shadow: var(--shadow-sm);
    transform: translateY(-2px);
  }
}

/* 小黑板块 */
.xiaohei-section {
  max-width: none;
  min-height: 100vh; min-height: 100dvh;
  display: flex; flex-direction: column; justify-content: center;
  padding-top: var(--space-2xl); padding-bottom: var(--space-2xl);
  background: var(--bg-secondary);
}
.xiaohei-section--alt {
  background:
    radial-gradient(ellipse 75% 55% at 50% 50%, var(--accent-subtle) 0%, transparent 68%),
    var(--bg-primary);
}
.xiaohei-features-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-xl);
  max-width: 1100px;
  margin: var(--space-2xl) auto 0;
}
.xiaohei-feature-card {
  display: flex; flex-direction: column;
  padding: var(--space-xl);
}
@media (hover: hover) {
  .xiaohei-feature-card:hover {
    box-shadow: var(--shadow-md);
  }
}
.xiaohei-feature-icon {
  width: 44px; height: 44px;
  display: flex; align-items: center; justify-content: center;
  border-radius: var(--radius-sm);
  background: var(--accent-subtle);
  color: var(--accent);
  margin-bottom: var(--space-md);
}
.xiaohei-feature-card h3 {
  font-size: var(--text-base); font-weight: 500;
  color: var(--text-primary);
  margin-bottom: var(--space-sm);
}
.xiaohei-feature-card p {
  font-size: var(--text-sm); color: var(--text-secondary);
  line-height: var(--lh-relaxed);
}
@media (max-width: 768px) {
  .xiaohei-features-grid { grid-template-columns: 1fr; }
}

/* 小黑场景卡片 */
.xiaohei-scenario-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-xl);
  max-width: 1100px;
  margin: var(--space-2xl) auto 0;
}
.xiaohei-scenario-card {
  padding: var(--space-2xl);
  display: flex; flex-direction: column;
  align-items: center; text-align: center;
  position: relative;
  overflow: hidden;
}
@media (hover: hover) {
  .xiaohei-scenario-card:hover {
    box-shadow: var(--shadow-md);
  }
  .xiaohei-scenario-card:hover .xiaohei-scenario-icon {
    transform: scale(1.08);
    background: var(--sage-subtle);
  }
}
.xiaohei-scenario-icon {
  width: 64px; height: 64px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%;
  background: var(--sage-subtle);
  color: var(--sage);
  margin-bottom: var(--space-xl);
  transition: transform 0.25s var(--ease-back), background 0.25s var(--ease-smooth);
}
.xiaohei-scenario-card h3 {
  font-size: var(--text-base); font-weight: 500;
  color: var(--text-primary);
  margin-bottom: var(--space-sm);
}
.xiaohei-scenario-card p {
  font-size: var(--text-sm); color: var(--text-secondary);
  line-height: var(--lh-relaxed);
}
@media (max-width: 768px) {
  .xiaohei-scenario-grid { grid-template-columns: 1fr; }
}

/* 关于板块 */
.about-page-section {
  min-height: 100vh; min-height: 100dvh;
  display: flex; flex-direction: column; justify-content: center;
  padding-top: var(--space-4xl); padding-bottom: var(--space-4xl);
  background: var(--bg-secondary);
  border-top: 1px solid var(--border);
}
.about-cta {
  margin-top: var(--space-3xl);
  text-align: center;
}

@media (max-width: 480px) {
  .products-diagram svg { min-height: 200px; }
}

/* Scenarios */
.allmall-products-section {
  max-width: none;
  min-height: 100vh; min-height: 100dvh;
  display: flex; flex-direction: column; justify-content: center;
  padding-top: var(--space-2xl); padding-bottom: var(--space-2xl);
  background: var(--bg-secondary);
}


/* Security */
.allmall-security-section {
  max-width: none;
  min-height: 100vh; min-height: 100dvh;
  display: flex; flex-direction: column; justify-content: center;
  padding-top: var(--space-2xl); padding-bottom: var(--space-2xl);
  background: var(--bg-primary);
}

/* Wide SVG diagram for concentric orbit layout */
.products-diagram--wide {
  max-width: 1000px;
  margin: 0 auto;
}

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 14px 36px;
  border-radius: var(--radius-md); font-size: var(--text-sm); font-weight: 600;
  min-height: 48px; min-width: 48px;
  position: relative; overflow: hidden;
  transition: transform 0.2s var(--ease-back), background 0.2s var(--ease-smooth), opacity 0.2s var(--ease-smooth);
}
.btn-primary {
  background: var(--accent);
  color: var(--accent-on);
  border: none;
}
.btn-primary::after {
  content: ''; position: absolute; inset: 0;
  background: rgba(255, 255, 255, 0.12); opacity: 0; transition: opacity 0.15s;
}
@media (hover: hover) {
  .btn-primary:hover { background: var(--accent-hover); }
  .btn-primary:hover::after { opacity: 1; }
}
.btn-primary:active { transform: scale(0.97); }
.btn-primary:active::after { opacity: 1; }
.btn-primary:focus-visible {
  outline: var(--focus-ring);
  outline-offset: var(--focus-ring-offset);
}
.btn-primary:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
}

.footer {
  padding: var(--space-2xl) var(--space-2xl);
  border-top: 1px solid var(--border);
}
.footer-inner {
  max-width: var(--max-width); margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr auto auto auto;
  gap: var(--space-lg) var(--space-xl);
  align-items: center;
}
.footer-legal {
  display: flex; flex-direction: column; gap: var(--space-xs);
  align-items: flex-end;
  text-align: right;
  font-size: var(--text-sm); color: var(--text-tertiary);
}
.footer-legal a {
  color: var(--text-tertiary);
  transition: color 0.2s var(--ease-smooth);
}
.footer-legal a:hover { color: var(--accent); }
.footer-legal a:focus-visible {
  outline: var(--focus-ring); outline-offset: 2px;
}
.footer-psb { display: inline-flex; align-items: center; gap: 2px; }
.footer-psb img { width: 16px; height: 16px; }
.footer-brand { display: flex; align-items: center; gap: var(--space-md); }
.footer-logo { font-size: var(--text-lg); font-weight: 700; color: var(--text-primary); }
.footer-tagline { font-size: var(--text-sm); color: var(--text-tertiary); font-weight: 500; }
.footer-links { display: flex; flex-wrap: wrap; gap: var(--space-lg); justify-content: center; }
.footer-links a, .footer-copy {
  font-size: var(--text-sm); color: var(--text-tertiary);
  transition: color 0.2s var(--ease-smooth);
}
.footer-links a:hover, .footer-links a:active { color: var(--text-secondary); }
.footer-links a:focus-visible { outline: var(--focus-ring); outline-offset: 2px; }
.footer-copy { justify-self: end; white-space: nowrap; }

/* Contact page fullscreen layout */
.contact-fullscreen {
  min-height: 100vh; min-height: 100dvh;
  display: flex; flex-direction: column; justify-content: center;
  padding-top: calc(var(--nav-height) + var(--space-4xl));
  padding-bottom: var(--space-4xl);
  background:
    radial-gradient(ellipse 80% 50% at 50% 0%, var(--accent-subtle) 0%, transparent 70%),
    radial-gradient(ellipse 40% 40% at 85% 80%, var(--sage-subtle) 0%, transparent 60%),
    var(--bg-primary);
}
.contact-fullscreen-inner {
  display: flex; flex-direction: column;
  max-width: 960px; margin: 0 auto;
  width: 100%;
}
.contact-fullscreen-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: start;
}
.contact-info-list {
  list-style: none;
  display: flex; flex-direction: column;
  gap: var(--space-2xl);
}
.contact-info-item {
  display: flex; gap: var(--space-md); align-items: flex-start;
}
.contact-info-icon {
  flex-shrink: 0; width: 40px; height: 40px;
  display: flex; align-items: center; justify-content: center;
  border-radius: var(--radius-sm); background: var(--sage-subtle);
  color: var(--sage);
}
.contact-info-label {
  display: block; font-size: var(--text-xs); font-weight: 600;
  color: var(--text-tertiary); text-transform: uppercase;
  letter-spacing: 0.06em; margin-bottom: var(--space-sm);
}
.contact-info-value {
  font-size: var(--text-sm); color: var(--text-primary);
  line-height: var(--lh-relaxed); font-style: normal;
}
.contact-info-link {
  font-weight: 500;
  transition: opacity 0.2s var(--ease-smooth);
}
@media (hover: hover) {
  .contact-info-link:hover { opacity: 0.8; }
}
/* 分场景联系 */
.contact-scenarios {
  display: flex; flex-direction: column; gap: var(--space-lg);
}
.contact-scenarios-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-md);
}
.contact-scenario-card {
  display: flex; flex-direction: column;
  padding: 20px;
}
.contact-scenario-card h4 {
  font-size: var(--text-sm); font-weight: 500;
  color: var(--text-primary);
  margin-bottom: var(--space-xs);
}
.contact-scenario-email {
  font-size: var(--text-xs); color: var(--text-secondary);
  line-height: var(--lh-normal);
  word-break: break-all;
}


.error-page {
  min-height: calc(100vh - var(--nav-height) - 120px);
  min-height: calc(100dvh - var(--nav-height) - 120px);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center; padding: var(--space-2xl);
}
.error-code {
  font-size: clamp(4rem, 18vw, 8rem); font-weight: 700; letter-spacing: -0.05em;
  color: var(--text-tertiary); line-height: 1; margin-bottom: var(--space-md);
}
.error-title { font-size: var(--text-xl); font-weight: 600; margin-bottom: var(--space-sm); color: var(--text-primary); }
.error-desc { font-size: var(--text-base); color: var(--text-secondary); margin-bottom: var(--space-xl); }

/* Animations */
[data-animate] {
  opacity: 0; transform: translateY(24px);
  transition: opacity 0.7s var(--ease-expo) calc(var(--stagger-index, 0) * 80ms),
              transform 0.7s var(--ease-expo) calc(var(--stagger-index, 0) * 80ms);
}
[data-animate].is-visible {
  opacity: 1; transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important; animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  html { scroll-behavior: auto; }
  [data-animate] { opacity: 1; transform: none; transition: none; }
}

@media (max-width: 1200px) {
  .footer-inner {
    grid-template-columns: 1fr 1fr;
    justify-items: start;
  }
  .footer-links { justify-content: flex-start; }
  .footer-legal { align-items: flex-start; text-align: left; }
  .footer-copy { justify-self: start; grid-column: 1 / -1; }
}
@media (max-width: 968px) {
  .section-header { grid-template-columns: 1fr; gap: var(--space-md); }
  .section-label { white-space: normal; }
  .key-stats { grid-template-columns: repeat(2, 1fr); gap: var(--space-xl); }
  .xiaohei-features-grid { grid-template-columns: 1fr; }
  .xiaohei-scenario-grid { grid-template-columns: repeat(2, 1fr); }
  .hero-title { font-size: var(--text-3xl); }
  html[lang="en"] .hero-title { font-size: clamp(1.75rem, 6vw, 2.75rem); }
  .section { padding-left: var(--space-lg); padding-right: var(--space-lg); }
  .nav { padding: 0 var(--space-lg); }
  .hero { padding-left: var(--space-lg); padding-right: var(--space-lg); }
  .footer-inner {
    grid-template-columns: 1fr;
    text-align: center;
    justify-items: center;
  }
  .footer-legal { align-items: center; text-align: center; }
  .footer-copy { justify-self: center; grid-column: auto; }
  .contact-fullscreen-content { grid-template-columns: 1fr; }
  .contact-scenarios-grid { grid-template-columns: repeat(2, 1fr); }
  .products-diagram svg { max-height: 200px; }
}

@media (max-width: 768px) {
  .hamburger { display: flex; }
  .nav-links {
    position: fixed; top: 0; right: 0;
    height: 100vh; height: 100dvh;
    width: min(280px, 85vw); flex-direction: column;
    align-items: stretch;
    background: var(--bg-primary); border-left: 1px solid var(--border);
    padding: calc(var(--nav-height) + var(--space-xl)) var(--space-xl) var(--space-xl);
    box-shadow: var(--shadow-md);
    transform: translateX(100%); transition: transform 0.35s var(--ease-expo);
    gap: var(--space-md); z-index: 99;
  }
  .nav-links.active { transform: translateX(0); }
  .nav-links a { font-size: var(--text-base); }
  .nav-lang { margin-top: var(--space-sm); padding-top: var(--space-sm); border-top: 1px solid var(--border); }
  .contact-scenarios-grid { grid-template-columns: 1fr; }
  .products-diagram svg { max-height: 160px; }
  .section-heading { font-size: var(--text-xl); }
  .hero-title { font-size: clamp(1.75rem, 5vw, 2.75rem); }
}
@media (max-width: 600px) {
  .hero-title { font-size: var(--text-2xl); }
  .hero-desc { font-size: var(--text-base); }
  .section-heading { font-size: var(--text-xl); }

  .stat-num { font-size: var(--text-2xl); min-height: var(--text-2xl); }
  .stat-num-text { font-size: var(--text-xl); }
  .hero-manifesto span { font-size: var(--text-xs); padding: var(--space-xs) 12px; }
  .section { padding-left: var(--space-md); padding-right: var(--space-md); }
  .key-stats { grid-template-columns: 1fr; }
  .allmall-products-section,
  .allmall-security-section { padding-top: var(--space-lg); padding-bottom: var(--space-lg); }
  .xiaohei-section { padding-top: var(--space-lg); padding-bottom: var(--space-lg); }
}

@media print {
  .nav, .hamburger, .nav-overlay, .skip-link, .scroll-hint {
    display: none !important;
  }
  body { background: #fff; color: #000; }
  [data-animate] { opacity: 1 !important; transform: none !important; }
  .section, .hero, .contact-fullscreen { padding: 1rem; }
  .hero, .about-page-section, .allmall-products-section, .allmall-security-section, .xiaohei-section, .contact-fullscreen { min-height: auto; }
  .card, .xiaohei-feature-card, .xiaohei-scenario-card {
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
  }

  a[href^="http"]::after { content: " (" attr(href) ")"; font-size: 0.85em; }
}
