/* ========== BASE ========== */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 6rem; }
body { overflow-x: hidden; }

/* 英文模式下已删除的 about.highlight 段落不占用空间 */
[data-i18n="about.highlight"]:empty { display: none; }

/* ========== NAVIGATION ========== */
.nav-link {
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: rgba(29,0,71,0.7);
  border-radius: 0.75rem;
  transition: all 0.3s;
  text-decoration: none;
}
.nav-link:hover, .nav-link.active {
  color: #1d0047;
  background: rgba(29,0,71,0.05);
}
.nav-dropdown { position: relative; }
.dropdown-menu {
  position: absolute;
  top: 100%;
  left: 0;
  margin-top: 0.5rem;
  width: 11rem;
  background: white;
  border-radius: 1rem;
  box-shadow: 0 20px 60px rgba(29,0,71,0.12);
  border: 1px solid rgba(29,0,71,0.05);
  padding: 0.5rem 0;
  opacity: 0;
  visibility: hidden;
  transform: translateY(0.5rem);
  transition: all 0.3s;
}
.nav-dropdown:hover .dropdown-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.dropdown-menu a {
  display: block;
  padding: 0.625rem 1rem;
  font-size: 0.875rem;
  color: rgba(29,0,71,0.6);
  text-decoration: none;
  transition: all 0.2s;
}
.dropdown-menu a:hover {
  color: #1d0047;
  background: rgba(29,0,71,0.05);
}
#navbar.scrolled {
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  box-shadow: 0 1px 3px rgba(29,0,71,0.06);
}

/* Ensure navbar is always clickable */
#navbar {
  pointer-events: auto;
}
#menuToggle {
  pointer-events: auto;
  position: relative;
  z-index: 60;
}
/* ========== MOBILE MENU ========== */
#mobileMenu {
  display: none;
}
#mobileMenu.open {
  display: block;
}

.mobile-menu-bg {
  background: linear-gradient(165deg, #1d0047 0%, #2d1b69 40%, #1a0533 100%);
  position: relative;
}
.mobile-menu-bg::before {
  content: '';
  position: absolute;
  top: -50%;
  right: -30%;
  width: 80%;
  height: 80%;
  background: radial-gradient(circle, rgba(168,85,247,0.15) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}
.mobile-menu-bg::after {
  content: '';
  position: absolute;
  bottom: -20%;
  left: -20%;
  width: 60%;
  height: 60%;
  background: radial-gradient(circle, rgba(192,38,211,0.1) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}

.mobile-nav-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 12px;
  border-radius: 12px;
  text-decoration: none;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  z-index: 1;
}
.mobile-nav-item:active {
  background: rgba(255,255,255,0.08);
  transform: scale(0.98);
}

.mobile-nav-num {
  font-size: 12px;
  font-weight: 600;
  color: rgba(168,85,247,0.6);
  font-family: var(--font-mono);
  min-width: 24px;
}

.mobile-nav-text {
  flex: 1;
  font-size: 18px;
  font-weight: 500;
  color: rgba(255,255,255,0.9);
  letter-spacing: 0.02em;
}

.mobile-nav-arrow {
  width: 18px;
  height: 18px;
  color: rgba(255,255,255,0.25);
  transition: all 0.3s;
}
.mobile-nav-item:active .mobile-nav-arrow {
  color: rgba(168,85,247,0.8);
  transform: translateX(4px);
}

.mobile-lang-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 12px 20px;
  border-radius: 100px;
  border: 1px solid rgba(255,255,255,0.15);
  background: rgba(255,255,255,0.05);
  color: rgba(255,255,255,0.8);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s;
  backdrop-filter: blur(10px);
}
.mobile-lang-btn:active {
  background: rgba(255,255,255,0.12);
  border-color: rgba(168,85,247,0.5);
}

.mobile-menu-copyright {
  margin-top: 16px;
  font-size: 12px;
  color: rgba(255,255,255,0.3);
  letter-spacing: 0.05em;
}

.mobile-nav-item.active {
  background: rgba(168,85,247,0.15);
}
.mobile-nav-item.active .mobile-nav-text {
  color: #a855f7;
}
.mobile-nav-item.active .mobile-nav-num {
  color: #a855f7;
}

/* Hamburger */
.hamburger { position: relative; width: 1.5rem; height: 1.25rem; }
.hamburger span {
  position: absolute;
  left: 0;
  width: 100%;
  height: 2px;
  background: #1d0047;
  border-radius: 9999px;
  transition: all 0.3s;
}
.hamburger span:nth-child(1) { top: 0; }
.hamburger span:nth-child(2) { top: 50%; transform: translateY(-50%); }
.hamburger span:nth-child(3) { bottom: 0; }

/* Hamburger open state - dark circle background */
#menuToggle {
  border-radius: 50%;
  transition: background 0.3s;
}
#menuToggle.open {
  background: rgba(29,0,71,0.9);
}
.hamburger.open span { background: #fff; }
.hamburger.open span:nth-child(1) { top: 50%; transform: translateY(-50%) rotate(45deg); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { bottom: 50%; transform: translateY(50%) rotate(-45deg); }

/* ========== HERO ========== */
.hero-gradient {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 20% 50%, rgba(29,0,71,0.06) 0%, transparent 70%),
    radial-gradient(ellipse 60% 80% at 80% 30%, rgba(107,33,168,0.04) 0%, transparent 70%),
    radial-gradient(ellipse 50% 50% at 60% 80%, rgba(192,38,211,0.03) 0%, transparent 70%);
}

/* ========== ORB FLOATING ANIMATIONS ========== */
@keyframes orbFloat1 {
  0%   { transform: translate(0, 0) scale(1); }
  25%  { transform: translate(80px, 60px) scale(1.08); }
  50%  { transform: translate(40px, 120px) scale(0.95); }
  75%  { transform: translate(-40px, 60px) scale(1.05); }
  100% { transform: translate(0, 0) scale(1); }
}
@keyframes orbFloat2 {
  0%   { transform: translate(0, 0) scale(1); }
  30%  { transform: translate(-60px, 80px) scale(1.1); }
  60%  { transform: translate(-100px, -40px) scale(0.92); }
  100% { transform: translate(0, 0) scale(1); }
}
@keyframes orbFloat3 {
  0%   { transform: translate(0, 0) scale(1); }
  35%  { transform: translate(100px, -60px) scale(1.06); }
  70%  { transform: translate(40px, 40px) scale(0.94); }
  100% { transform: translate(0, 0) scale(1); }
}
@keyframes orbFloat4 {
  0%   { transform: translate(0, 0) scale(1); opacity: 0.08; }
  50%  { transform: translate(-30px, 50px) scale(1.2); opacity: 0.12; }
  100% { transform: translate(0, 0) scale(1); opacity: 0.08; }
}
@keyframes orbFloat5 {
  0%   { transform: translate(0, 0) scale(1); opacity: 0.06; }
  40%  { transform: translate(40px, -30px) scale(1.3); opacity: 0.1; }
  100% { transform: translate(0, 0) scale(1); opacity: 0.06; }
}
.orb-float-1 { animation: orbFloat1 18s ease-in-out infinite; }
.orb-float-2 { animation: orbFloat2 22s ease-in-out infinite; }
.orb-float-3 { animation: orbFloat3 20s ease-in-out infinite; }
.orb-float-4 { animation: orbFloat4 14s ease-in-out infinite; }
.orb-float-5 { animation: orbFloat5 16s ease-in-out infinite 2s; }

/* ========== ABOUT TAB SWITCH ========== */
.about-tab {
  padding: 0.625rem 1.75rem;
  font-size: 0.875rem;
  font-weight: 600;
  color: rgba(29,0,71,0.5);
  border: 2px solid rgba(29,0,71,0.1);
  border-radius: 9999px;
  cursor: pointer;
  background: transparent;
  transition: all 0.3s;
}
.about-tab:hover {
  color: #1d0047;
  border-color: rgba(29,0,71,0.3);
}
.about-tab.active {
  color: white;
  border-color: transparent;
  background: linear-gradient(135deg, #6b21a8, #c026d3);
  box-shadow: 0 4px 16px rgba(107,33,168,0.3);
}
.about-tab-content {
  display: none;
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}
.about-tab-content.active {
  display: block;
  opacity: 1;
  transform: translateY(0);
}

/* ========== ANIMATIONS ========== */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(30px); }
  to { opacity: 1; transform: translateY(0); }
}
.animate-fadeUp {
  animation: fadeUp 0.8s ease-out forwards;
  opacity: 0;
}
.delay-100 { animation-delay: 0.1s; }
.delay-200 { animation-delay: 0.2s; }
.delay-300 { animation-delay: 0.3s; }

/* Scroll reveal */
.reveal {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ========== BUTTONS ========== */
.btn-primary {
  display: inline-flex;
  align-items: center;
  padding: 0.875rem 2rem;
  border-radius: 1rem;
  font-size: 0.875rem;
  font-weight: 600;
  color: white;
  text-decoration: none;
  transition: all 0.3s;
  background: linear-gradient(135deg, #1d0047 0%, #6b21a8 50%, #c026d3 100%);
  background-size: 200% auto;
  border: none;
  cursor: pointer;
}
.btn-primary:hover {
  background-position: right center;
  box-shadow: 0 12px 32px rgba(107,33,168,0.25);
  transform: scale(1.02);
}
.btn-outline {
  display: inline-flex;
  align-items: center;
  padding: 0.875rem 2rem;
  border-radius: 1rem;
  font-size: 0.875rem;
  font-weight: 600;
  color: #1d0047;
  text-decoration: none;
  border: 2px solid rgba(29,0,71,0.15);
  transition: all 0.3s;
  background: transparent;
  cursor: pointer;
}
.btn-outline:hover {
  border-color: #1d0047;
  background: #1d0047;
  color: white;
}

/* ========== SECTION COMMON ========== */
.section-tag {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: rgba(58,13,122,0.6);
  margin-bottom: 1rem;
}
.section-title {
  font-size: clamp(1.75rem, 4vw, 3rem);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 1.5rem;
  color: #1d0047;
}

/* ========== BUSINESS CARDS ========== */
.biz-card {
  position: relative;
  background: white;
  border-radius: 1.5rem;
  padding: 2.25rem 2.5rem;
  border: 1px solid rgba(29,0,71,0.06);
  box-shadow: 0 10px 40px rgba(29,0,71,0.06);
  overflow: hidden;
  transition: all 0.4s ease;
}
/* 卡片顶部装饰渐变条 */
.biz-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, #1d0047, #c026d3, #e11d8f);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.4s ease;
}
.biz-card:hover {
  box-shadow: 0 24px 70px rgba(107,33,168,0.18);
  border-color: rgba(192,38,211,0.25);
  transform: translateY(-6px);
}
.biz-card:hover::before { transform: scaleX(1); }
.biz-icon {
  width: 4rem;
  height: 4rem;
  border-radius: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.5rem;
  color: white;
  box-shadow: 0 8px 24px rgba(107,33,168,0.25);
  transition: transform 0.4s ease, box-shadow 0.4s ease;
}
/* 三张卡的图标渐变递进：深紫 → 紫 → 品红 → 粉 */
.biz-card:nth-child(1) .biz-icon { background: linear-gradient(135deg, #1d0047, #6b21a8); }
.biz-card:nth-child(2) .biz-icon { background: linear-gradient(135deg, #6b21a8, #c026d3); }
.biz-card:nth-child(3) .biz-icon { background: linear-gradient(135deg, #c026d3, #e11d8f); }
.biz-card:hover .biz-icon {
  transform: scale(1.08) rotate(-3deg);
  box-shadow: 0 12px 32px rgba(192,38,211,0.4);
}
.tag {
  padding: 0.3rem 0.85rem;
  border-radius: 9999px;
  background: rgba(107,33,168,0.09);
  font-size: 0.75rem;
  font-weight: 600;
  color: #6b21a8;
  transition: all 0.3s ease;
}
.biz-card:hover .tag {
  background: rgba(192,38,211,0.14);
  color: #a21caf;
}

/* ========== COMPLIANCE FRAMEWORK ========== */
.compliance-section {
  background: rgba(29,0,71,0.02);
  border-top: 1px solid rgba(29,0,71,0.05);
  border-bottom: 1px solid rgba(29,0,71,0.05);
}
.compliance-intro-layout {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  gap: 1.5rem 2rem;
  align-items: start;
}
.compliance-intro-layout .section-tag {
  grid-column: span 3 / span 3;
  margin: 0.35rem 0 0;
}
.compliance-intro {
  grid-column: span 9 / span 9;
  max-width: none;
  color: rgba(29,0,71,0.68);
  font-size: 1.0625rem;
  line-height: 1.75;
}
.compliance-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}
.compliance-card {
  display: flex;
  min-height: 18.5rem;
  flex-direction: column;
  padding: 1.75rem;
  background: #fff;
  border: 1px solid rgba(29,0,71,0.05);
  border-radius: 0.5rem;
  box-shadow: 0 1px 2px rgba(29,0,71,0.04);
  transition: border-color 0.25s ease, box-shadow 0.25s ease, transform 0.25s ease;
}
.compliance-card:hover {
  border-color: rgba(107,33,168,0.28);
  box-shadow: 0 12px 28px rgba(29,0,71,0.09);
  transform: translateY(-3px);
}
.compliance-icon {
  display: flex;
  width: 2.75rem;
  height: 2.75rem;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.5rem;
  color: #7e22ce;
  background: rgba(126,34,206,0.09);
  border: 1px solid rgba(126,34,206,0.16);
  border-radius: 0.5rem;
}
.compliance-icon svg { width: 1.4rem; height: 1.4rem; }
.compliance-card:nth-child(2) .compliance-icon,
.compliance-card:nth-child(5) .compliance-icon {
  color: #059669;
  background: rgba(5,150,105,0.09);
  border-color: rgba(5,150,105,0.16);
}
.compliance-card:nth-child(3) .compliance-icon,
.compliance-card:nth-child(6) .compliance-icon {
  color: #fff;
  background: linear-gradient(135deg, #7e22ce, #10b981);
  border-color: transparent;
}
.compliance-card-label,
.compliance-lifecycle-label {
  margin: 0 0 0.625rem;
  color: #6b21a8;
  font-size: 0.6875rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  line-height: 1.3;
}
.compliance-card:nth-child(2) .compliance-card-label,
.compliance-card:nth-child(5) .compliance-card-label { color: #059669; }
.compliance-card-title {
  margin: 0 0 0.75rem;
  color: #1d0047;
  font-size: 1.125rem;
  font-weight: 700;
  line-height: 1.4;
}
.compliance-card-desc {
  margin: 0;
  color: rgba(29,0,71,0.66);
  font-size: 0.9375rem;
  line-height: 1.75;
}
.compliance-lifecycle {
  display: grid;
  grid-template-columns: 10rem minmax(0, 1fr);
  gap: 1.5rem;
  align-items: start;
  margin-top: 1rem;
  padding: 1.5rem 1.75rem;
  color: rgba(29,0,71,0.72);
  font-size: 0.9375rem;
  line-height: 1.75;
  background: #fff;
  border: 1px solid rgba(29,0,71,0.05);
  border-left: 3px solid #6b21a8;
}
.compliance-lifecycle-label { margin: 0; padding-top: 0.125rem; }
.compliance-lifecycle p:last-child { margin: 0; }

/* ========== PIPELINE ========== */
.pipeline-row {
  display: grid;
  grid-template-columns: repeat(12, minmax(0, 1fr));
  background: white;
  border-radius: 1rem;
  border: 1px solid rgba(29,0,71,0.05);
  transition: all 0.3s;
}
.pipeline-row:hover {
  box-shadow: 0 8px 30px rgba(29,0,71,0.06);
  border-color: rgba(107,33,168,0.2);
}
.pipeline-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.5s;
}
.pipeline-row:hover .pipeline-bar {
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  filter: brightness(1.1);
}

/* ========== JOURNEY STEPS ========== */
.journey-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 0.75rem;
  border-radius: 0.75rem;
  min-width: 80px;
  flex-shrink: 0;
}
.journey-arrow {
  color: rgba(29,0,71,0.2);
  font-size: 1.125rem;
  flex-shrink: 0;
}

/* ========== NEWS CARDS ========== */
.news-card {
  background: white;
  border-radius: 1.5rem;
  overflow: hidden;
  border: 1px solid rgba(29,0,71,0.05);
  transition: all 0.5s;
  cursor: pointer;
}
.news-card:hover {
  box-shadow: 0 20px 60px rgba(29,0,71,0.05);
  transform: translateY(-4px);
}
.news-card-img {
  aspect-ratio: 16/9;
  background: linear-gradient(135deg, rgba(29,0,71,0.05), rgba(192,38,211,0.05));
  display: flex;
  align-items: center;
  justify-content: center;
}
.news-card-body {
  padding: 1.5rem 2rem;
}

/* ========== NEWS CARDS VERTICAL (图片在上，文字在下) ========== */
.news-card-vertical {
  background: white;
  border-radius: 1rem;
  overflow: hidden;
  border: 1px solid rgba(29,0,71,0.05);
  transition: all 0.3s ease;
  cursor: pointer;
  display: flex;
  flex-direction: column;
}
.news-card-vertical:hover {
  box-shadow: 0 12px 32px rgba(109, 40, 217, 0.12);
  transform: translateY(-4px);
}
.news-card-img-vertical {
  width: 100%;
  aspect-ratio: 16/9;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
}
.news-card-body-vertical {
  padding: 1.5rem;
  flex: 1;
}
.line-clamp-2 {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.line-clamp-3 {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* ========== TEAM GRID (Compact TJ-Bio Style) ========== */
.team-card-compact {
  cursor: pointer;
  padding: 0.25rem;
  transition: all 0.3s;
}
.team-card-compact:hover {
  transform: translateY(-2px);
}
.team-avatar-compact {
  aspect-ratio: 3/3.5;
  border-radius: 1rem;
  background: linear-gradient(135deg, rgba(29,0,71,0.04), rgba(192,38,211,0.04));
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.4s;
  border: 1px solid rgba(29,0,71,0.06);
}
.team-card-compact:hover .team-avatar-compact {
  box-shadow: 0 12px 40px rgba(29,0,71,0.08);
  border-color: rgba(192,38,211,0.2);
}

/* ========== JOB CARD ========== */
.job-card {
  background: white;
  border-radius: 1rem;
  padding: 1.5rem;
  border: 1px solid rgba(29,0,71,0.05);
  transition: all 0.3s;
}
.job-card:hover {
  box-shadow: 0 8px 30px rgba(29,0,71,0.06);
  border-color: rgba(107,33,168,0.2);
}

/* ========== PROSE (News Detail) ========== */
.prose-brand { color: rgba(29,0,71,0.7); }
.prose-brand h2 { font-size: 1.25rem; font-weight: 700; color: #1d0047; margin-top: 2rem; margin-bottom: 1rem; }
.prose-brand h3 { font-size: 1.125rem; font-weight: 700; color: #1d0047; margin-top: 1.5rem; margin-bottom: 0.75rem; }
.prose-brand p { margin-bottom: 1rem; line-height: 1.75; }
.prose-brand ul { list-style: disc; padding-left: 1.5rem; margin-bottom: 1rem; }
.prose-brand ul li { margin-bottom: 0.5rem; }
.prose-brand img { border-radius: 1rem; margin: 1.5rem 0; width: 100%; }
.prose-brand blockquote {
  border-left: 4px solid rgba(107,33,168,0.3);
  padding-left: 1rem;
  font-style: italic;
  color: rgba(29,0,71,0.5);
  margin: 1.5rem 0;
}

/* ========== STAT COUNTER ========== */
.stat-item { position: relative; }
.stat-item::after {
  content: '';
  position: absolute;
  top: 50%;
  right: 0;
  transform: translateY(-50%);
  width: 1px;
  height: 2rem;
  background: rgba(255,255,255,0.15);
}
.stat-item:last-child::after { display: none; }

/* ========== CANVAS ========== */
#heroCanvas { pointer-events: none; }

/* ========== RESPONSIVE ========== */
@media (max-width: 1023px) {
  .section-title { font-size: 1.5rem; }
  .biz-card { padding: 1.5rem; }
  .compliance-intro-layout { grid-template-columns: 1fr; gap: 0; }
  .compliance-intro-layout .section-tag { grid-column: auto; margin: 0 0 1rem; }
  .compliance-intro { grid-column: auto; }
  .compliance-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .news-card-body { padding: 1.25rem; }
  .news-card-body-vertical { padding: 1.25rem; }
  .news-card-img-vertical { height: 140px; }
}

@media (max-width: 767px) {
  .compliance-grid { grid-template-columns: 1fr; }
  .compliance-card { min-height: 0; padding: 1.5rem; }
  .compliance-lifecycle { grid-template-columns: 1fr; gap: 0.5rem; padding: 1.25rem 1.5rem; }
}
