/* =========================================================
   Jiule Innovation — Shared Styles
   Black minimalism with slow aurora + fine grain
   ========================================================= */

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  min-height: 100vh;
  color: var(--text);
  background: var(--bg);
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
img, svg { display: block; max-width: 100%; }
ul { list-style: none; }

/* ---------- Design Tokens ---------- */
:root {
  --bg: #0A0A0A;
  --bg-2: #121212;
  --border: rgba(255, 255, 255, 0.08);
  --border-hover: rgba(255, 255, 255, 0.18);
  --text: #F2F2F2;
  --text-muted: #8A8A8A;
  --text-subtle: #5A5A5A;
  --accent: #C7CDE0;

  --font: "Inter", -apple-system, BlinkMacSystemFont, "Helvetica Neue",
          "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei",
          "Noto Sans SC", sans-serif;
  --font-mono: ui-monospace, "SF Mono", "JetBrains Mono", Consolas, monospace;

  --max-w: 1140px;
  --pad-x: clamp(20px, 4vw, 40px);
  --radius: 14px;
}

/* ---------- Aurora background ---------- */
.aurora {
  position: fixed;
  inset: 0;
  z-index: -2;
  overflow: hidden;
  pointer-events: none;
  background: radial-gradient(ellipse 80% 50% at 50% 0%, rgba(60, 80, 150, 0.15), transparent 70%);
}
.aurora__blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  will-change: transform;
  mix-blend-mode: screen;
}
.aurora__blob--a {
  width: 820px; height: 820px;
  background: radial-gradient(circle, #4a6cff 0%, rgba(74,108,255,0.4) 30%, transparent 65%);
  top: -240px; left: -180px;
  opacity: 0.55;
  animation: drift-a 22s ease-in-out infinite alternate;
}
.aurora__blob--b {
  width: 760px; height: 760px;
  background: radial-gradient(circle, #a040ff 0%, rgba(160,64,255,0.35) 30%, transparent 65%);
  bottom: -220px; right: -180px;
  opacity: 0.5;
  animation: drift-b 26s ease-in-out infinite alternate;
}
.aurora__blob--c {
  width: 680px; height: 680px;
  background: radial-gradient(circle, #40c8e0 0%, rgba(64,200,224,0.3) 30%, transparent 65%);
  top: 45%; left: 50%;
  transform: translate(-50%, -50%);
  opacity: 0.35;
  animation: drift-c 30s ease-in-out infinite alternate;
}
.aurora__blob--d {
  width: 540px; height: 540px;
  background: radial-gradient(circle, #ff5090 0%, rgba(255,80,144,0.25) 30%, transparent 65%);
  top: 60%; left: 15%;
  opacity: 0.3;
  animation: drift-d 34s ease-in-out infinite alternate;
}

@keyframes drift-a {
  0%   { transform: translate(0, 0) scale(1); }
  100% { transform: translate(120px, 80px) scale(1.15); }
}
@keyframes drift-b {
  0%   { transform: translate(0, 0) scale(1); }
  100% { transform: translate(-100px, -100px) scale(1.12); }
}
@keyframes drift-c {
  0%   { transform: translate(-50%, -50%) scale(1); }
  100% { transform: translate(-30%, -70%) scale(1.2); }
}
@keyframes drift-d {
  0%   { transform: translate(0, 0) scale(1); }
  100% { transform: translate(180px, -100px) scale(1.18); }
}

/* ---------- Grain overlay ---------- */
.grain {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: 0.06;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='240' height='240'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 1  0 0 0 0 1  0 0 0 0 1  0 0 0 0.9 0'/></filter><rect width='240' height='240' filter='url(%23n)'/></svg>");
}

/* ---------- Navigation ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(10, 10, 10, 0.6);
  backdrop-filter: blur(20px) saturate(1.2);
  -webkit-backdrop-filter: blur(20px) saturate(1.2);
  border-bottom: 1px solid var(--border);
}
.nav__inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 18px var(--pad-x);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
}
.nav__brand {
  display: flex;
  align-items: center;
  gap: 12px;
  font-weight: 500;
  font-size: 15px;
  letter-spacing: 0.02em;
}
.nav__brand img {
  width: 32px; height: 32px;
  border-radius: 50%;
}
.nav__links {
  display: flex;
  align-items: center;
  gap: 6px;
}
.nav__links a {
  padding: 8px 14px;
  border-radius: 8px;
  font-size: 14px;
  color: var(--text-muted);
  transition: color 0.2s, background 0.2s;
}
.nav__links a:hover { color: var(--text); background: rgba(255,255,255,0.04); }
.nav__links a.active { color: var(--text); }

.nav__lang {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 6px 10px;
  border: 1px solid var(--border);
  border-radius: 999px;
  font-size: 12px;
  color: var(--text-muted);
  transition: border-color 0.2s, color 0.2s;
}
.nav__lang:hover { border-color: var(--border-hover); color: var(--text); }
.nav__lang svg { width: 12px; height: 12px; }

/* ---------- Layout ---------- */
main { position: relative; z-index: 1; }
.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 var(--pad-x);
}

/* ---------- Hero ---------- */
.hero {
  padding: clamp(80px, 14vh, 160px) 0 clamp(70px, 10vh, 120px);
}
.hero__eyebrow {
  display: inline-block;
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
  padding: 6px 14px;
  border: 1px solid var(--border);
  border-radius: 999px;
  margin-bottom: 28px;
}
.hero__title {
  font-size: clamp(38px, 6vw, 68px);
  font-weight: 500;
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin-bottom: 24px;
  max-width: 20ch;
}
.hero__title em {
  font-style: normal;
  background: linear-gradient(120deg, #FFFFFF 0%, #A8B0C8 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero__subtitle {
  font-size: clamp(16px, 1.6vw, 19px);
  color: var(--text-muted);
  max-width: 62ch;
  margin-bottom: 44px;
  line-height: 1.55;
}
.hero__actions { display: flex; gap: 12px; flex-wrap: wrap; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 22px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.01em;
  transition: transform 0.15s, background 0.2s, border-color 0.2s;
  cursor: pointer;
  border: 1px solid transparent;
}
.btn:hover { transform: translateY(-1px); }
.btn--primary {
  background: var(--text);
  color: var(--bg);
}
.btn--primary:hover { background: #E0E0E0; }
.btn--ghost {
  background: transparent;
  color: var(--text);
  border-color: var(--border-hover);
}
.btn--ghost:hover { border-color: var(--text); background: rgba(255,255,255,0.04); }
.btn__arrow {
  display: inline-block;
  transition: transform 0.2s;
}
.btn:hover .btn__arrow { transform: translateX(3px); }

/* ---------- Sections ---------- */
.section {
  padding: clamp(60px, 10vh, 110px) 0;
  border-top: 1px solid var(--border);
}
.section__head { margin-bottom: 56px; max-width: 60ch; }
.section__eyebrow {
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 20px;
}
.section__title {
  font-size: clamp(28px, 3.6vw, 42px);
  font-weight: 500;
  letter-spacing: -0.015em;
  line-height: 1.15;
  margin-bottom: 20px;
}
.section__lead {
  font-size: 17px;
  color: var(--text-muted);
  line-height: 1.6;
}

/* ---------- Cards / Grid ---------- */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
}
@media (max-width: 820px) {
  .grid-3, .grid-2 { grid-template-columns: 1fr; }
}

.card {
  padding: 32px 28px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: rgba(255,255,255,0.015);
  transition: border-color 0.25s, background 0.25s, transform 0.25s;
}
.card:hover {
  border-color: var(--border-hover);
  background: rgba(255,255,255,0.03);
  transform: translateY(-2px);
}
.card__num {
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-subtle);
  letter-spacing: 0.1em;
  margin-bottom: 20px;
}
.card__title {
  font-size: 18px;
  font-weight: 500;
  letter-spacing: -0.01em;
  margin-bottom: 12px;
}
.card__body {
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.6;
}

/* ---------- Prose (About / Legal body) ---------- */
.prose {
  max-width: 68ch;
  color: var(--text-muted);
  font-size: 16px;
  line-height: 1.75;
}
.prose h2 {
  color: var(--text);
  font-size: 22px;
  font-weight: 500;
  letter-spacing: -0.01em;
  margin-top: 40px;
  margin-bottom: 16px;
}
.prose h3 {
  color: var(--text);
  font-size: 17px;
  font-weight: 500;
  margin-top: 32px;
  margin-bottom: 12px;
}
.prose p { margin-bottom: 18px; }
.prose ul { margin: 0 0 18px 22px; }
.prose ul li {
  list-style: disc;
  margin-bottom: 8px;
}
.prose strong { color: var(--text); font-weight: 500; }
.prose a { color: var(--text); border-bottom: 1px solid var(--border-hover); }
.prose a:hover { border-bottom-color: var(--text); }

/* ---------- Info blocks ---------- */
.info-grid {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 24px 40px;
  padding: 32px 0;
  border-top: 1px solid var(--border);
}
.info-grid:last-child { border-bottom: 1px solid var(--border); }
.info-grid dt {
  font-size: 13px;
  color: var(--text-subtle);
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.info-grid dd {
  font-size: 16px;
  color: var(--text);
  line-height: 1.6;
}
@media (max-width: 640px) {
  .info-grid { grid-template-columns: 1fr; gap: 8px; padding: 24px 0; }
}

/* ---------- Legal index cards ---------- */
.legal-list { display: grid; gap: 14px; max-width: 720px; }
.legal-list a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 24px 28px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  transition: border-color 0.2s, background 0.2s, transform 0.2s;
}
.legal-list a:hover {
  border-color: var(--border-hover);
  background: rgba(255,255,255,0.02);
  transform: translateX(2px);
}
.legal-list h3 { font-size: 17px; font-weight: 500; margin-bottom: 4px; }
.legal-list p { font-size: 13px; color: var(--text-muted); }
.legal-list__arrow { color: var(--text-subtle); font-size: 20px; }

/* ---------- Footer ---------- */
.footer {
  border-top: 1px solid var(--border);
  padding: 60px 0 40px;
  margin-top: 60px;
  position: relative;
  z-index: 1;
}
.footer__top {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 48px;
}
@media (max-width: 820px) {
  .footer__top { grid-template-columns: 1fr 1fr; gap: 32px; }
}
.footer__brand { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.footer__brand img { width: 32px; height: 32px; border-radius: 50%; }
.footer__brand span { font-size: 14px; font-weight: 500; }
.footer__tagline {
  font-size: 13px;
  color: var(--text-muted);
  max-width: 32ch;
  line-height: 1.6;
}
.footer__col h4 {
  font-size: 11px;
  font-weight: 500;
  color: var(--text-subtle);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  margin-bottom: 16px;
}
.footer__col ul li { margin-bottom: 10px; }
.footer__col a {
  font-size: 13px;
  color: var(--text-muted);
  transition: color 0.2s;
}
.footer__col a:hover { color: var(--text); }

.footer__bottom {
  border-top: 1px solid var(--border);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 12px;
  color: var(--text-subtle);
}
.footer__bottom a { color: var(--text-subtle); }
.footer__bottom a:hover { color: var(--text-muted); }
.footer__legal { display: flex; gap: 20px; flex-wrap: wrap; }

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  .aurora__blob { animation: none; }
  * { transition: none !important; }
}

/* ---------- Small helpers ---------- */
.mono { font-family: var(--font-mono); }
.text-muted { color: var(--text-muted); }
.mt-0 { margin-top: 0; }
