/* ==========================================================================
   ANGJUJU — corporate site design system
   Layout language borrowed from Xiaomi EV: full-viewport product stages,
   oversized product names, hairline spec strips, ghost pill buttons.
   ========================================================================== */

:root {
  --ink: #0a0b0d;
  --ink-2: #12141a;
  --ink-3: #1b1e26;
  --paper: #ffffff;
  --paper-2: #f5f6f8;
  --line-dark: rgba(255, 255, 255, 0.14);
  --line-light: rgba(10, 11, 13, 0.12);
  --text-on-dark: #f2f4f7;
  --muted-on-dark: rgba(242, 244, 247, 0.62);
  --faint-on-dark: rgba(242, 244, 247, 0.38);
  --text-on-light: #12141a;
  --muted-on-light: rgba(18, 20, 26, 0.62);
  --accent: #ff5b2e;
  --accent-teal: #2fd6c0;
  --accent-blue: #4d7cfe;
  --accent-violet: #a980ff;
  --nav-h: 64px;
  --gutter: clamp(20px, 5vw, 88px);
  --maxw: 1240px;
  --radius: 22px;
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--ink);
  color: var(--text-on-dark);
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.65;
  font-weight: 400;
  letter-spacing: -0.005em;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, h4, p, figure, ul { margin: 0; padding: 0; }
ul { list-style: none; }

/* ---------- shared type scale ---------- */
.eyebrow {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--faint-on-dark);
}
.stage-title {
  font-size: clamp(40px, 6.4vw, 88px);
  line-height: 0.98;
  font-weight: 700;
  letter-spacing: -0.035em;
}
.stage-sub {
  font-size: clamp(17px, 1.5vw, 22px);
  line-height: 1.5;
  font-weight: 500;
  letter-spacing: -0.02em;
  color: var(--muted-on-dark);
}
.section-title {
  font-size: clamp(28px, 3.4vw, 46px);
  line-height: 1.1;
  font-weight: 700;
  letter-spacing: -0.03em;
}
.body-copy { color: var(--muted-on-dark); max-width: 62ch; }
.on-light .body-copy { color: var(--muted-on-light); }
.on-light .eyebrow { color: rgba(18, 20, 26, 0.42); }
.on-light .stage-sub { color: var(--muted-on-light); }
.mono { font-variant-numeric: tabular-nums; font-feature-settings: "tnum"; }

/* ---------- buttons ---------- */
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 46px;
  padding: 0 26px;
  border-radius: 999px;
  border: 1px solid var(--line-dark);
  font-size: 15px;
  font-weight: 600;
  letter-spacing: -0.01em;
  color: var(--text-on-dark);
  background: rgba(255, 255, 255, 0.04);
  backdrop-filter: blur(6px);
  transition: transform 0.35s var(--ease), background 0.35s var(--ease), border-color 0.35s var(--ease), color 0.35s var(--ease);
}
.btn:hover { background: rgba(255, 255, 255, 0.14); border-color: rgba(255, 255, 255, 0.4); transform: translateY(-1px); }
.btn-solid { background: var(--text-on-dark); color: var(--ink); border-color: transparent; }
.btn-solid:hover { background: #fff; }
.btn-accent { background: var(--accent); border-color: transparent; color: #fff; }
.btn-accent:hover { background: #ff7048; }
.on-light .btn { color: var(--text-on-light); border-color: var(--line-light); background: rgba(10, 11, 13, 0.03); }
.on-light .btn:hover { background: rgba(10, 11, 13, 0.09); border-color: rgba(10, 11, 13, 0.3); }
.on-light .btn-solid { background: var(--ink); color: #fff; }
.on-light .btn-accent { background: var(--accent); color: #fff; }

/* ---------- top navigation ---------- */
.nav {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 90;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  gap: 28px;
  padding: 0 var(--gutter);
  transition: background 0.4s var(--ease), border-color 0.4s var(--ease), color 0.4s var(--ease);
  border-bottom: 1px solid transparent;
}
.nav.solid {
  background: rgba(10, 11, 13, 0.72);
  backdrop-filter: saturate(160%) blur(18px);
  border-bottom-color: var(--line-dark);
}
.nav.light-zone { color: var(--text-on-light); }
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 17px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  margin-right: auto;
}
.brand .dot { width: 9px; height: 9px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 14px var(--accent); }
.nav-links { display: flex; align-items: center; gap: 26px; }
.nav-links a {
  font-size: 14px;
  font-weight: 500;
  letter-spacing: -0.005em;
  opacity: 0.78;
  transition: opacity 0.25s var(--ease);
}
.nav-links a:hover { opacity: 1; }
.nav-cta {
  font-size: 13px;
  font-weight: 600;
  padding: 9px 18px;
  border-radius: 999px;
  border: 1px solid currentColor;
  opacity: 0.9;
  white-space: nowrap;
}
.nav-cta:hover { opacity: 1; background: currentColor; }
.nav-cta:hover span { mix-blend-mode: difference; color: #fff; }
@media (max-width: 900px) {
  .nav-links { display: none; }
}

/* ---------- product stage ---------- */
.stage {
  position: relative;
  min-height: 100svh;
  padding: calc(var(--nav-h) + clamp(40px, 7vh, 96px)) var(--gutter) clamp(56px, 9vh, 120px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  overflow: hidden;
  isolation: isolate;
}
.stage.on-light { background: var(--paper); color: var(--text-on-light); }
.stage-inner { width: 100%; max-width: var(--maxw); margin: 0 auto; }
.stage-head { display: flex; flex-direction: column; gap: 18px; align-items: flex-start; }
.stage-copy { display: grid; gap: 26px; max-width: 720px; }
.halo {
  position: absolute;
  inset: -20% -10% auto auto;
  width: min(90vw, 1100px);
  aspect-ratio: 1;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.5;
  z-index: -2;
  pointer-events: none;
}
.grain {
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  opacity: 0.35;
  background-image: radial-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px);
  background-size: 3px 3px;
}
.on-light .grain { opacity: 0.06; background-image: radial-gradient(rgba(0, 0, 0, 0.5) 1px, transparent 1px); }

/* ---------- device frames ---------- */
.shot { position: relative; margin: 0; }
.shot figcaption { margin-top: 14px; font-size: 12.5px; color: var(--faint-on-dark); letter-spacing: 0.02em; }
.on-light .shot figcaption { color: rgba(18, 20, 26, 0.42); }

.screen {
  position: relative;
  border-radius: 14px;
  overflow: hidden;
  background: #05070a;
  box-shadow: 0 40px 90px -30px rgba(0, 0, 0, 0.8), 0 0 0 1px rgba(255, 255, 255, 0.09);
}
.screen img { width: 100%; height: 100%; object-fit: cover; }
.chrome { border-top-left-radius: 14px; border-top-right-radius: 14px; }
.chrome::before {
  content: "";
  display: block;
  height: 30px;
  background: #16181f;
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
  background-image: radial-gradient(circle at 14px 15px, #ff5f57 3px, transparent 4px),
    radial-gradient(circle at 30px 15px, #febc2e 3px, transparent 4px),
    radial-gradient(circle at 46px 15px, #28c840 3px, transparent 4px);
}

.phone {
  position: relative;
  width: min(320px, 74vw);
  aspect-ratio: 9 / 19.5;
  border-radius: 40px;
  padding: 10px;
  background: linear-gradient(160deg, #2a2d36, #0d0f13 60%);
  box-shadow: 0 50px 100px -34px rgba(0, 0, 0, 0.85), inset 0 0 0 1px rgba(255, 255, 255, 0.12);
}
.phone .screen { height: 100%; border-radius: 30px; box-shadow: none; }
.phone::after {
  content: "";
  position: absolute;
  top: 16px; left: 50%;
  transform: translateX(-50%);
  width: 74px; height: 6px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.55);
  z-index: 2;
}
.phone-wide {
  aspect-ratio: 16 / 9;
  width: min(560px, 88vw);
  border-radius: 22px;
}
.phone-wide::after { display: none; }
.phone-wide .screen { border-radius: 14px; }

/* ---------- spec strip ---------- */
.specs {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 1px;
  margin-top: 40px;
  background: var(--line-dark);
  border-radius: 16px;
  overflow: hidden;
}
.on-light .specs { background: var(--line-light); }
.spec {
  padding: 22px 20px 24px;
  background: rgba(10, 11, 13, 0.55);
  backdrop-filter: blur(8px);
}
.on-light .spec { background: var(--paper); }
.spec b {
  display: block;
  font-size: clamp(26px, 3vw, 40px);
  line-height: 1;
  font-weight: 700;
  letter-spacing: -0.04em;
}
.spec b i { font-style: normal; font-size: 0.45em; font-weight: 600; margin-left: 4px; opacity: 0.6; letter-spacing: 0; }
.spec span { display: block; margin-top: 10px; font-size: 12.5px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--faint-on-dark); }
.on-light .spec span { color: rgba(18, 20, 26, 0.45); }

/* ---------- feature list ---------- */
.features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: clamp(20px, 3vw, 40px);
  margin-top: 46px;
}
.feature { display: grid; gap: 10px; align-content: start; }
.feature h4 { font-size: 17px; font-weight: 650; letter-spacing: -0.02em; }
.feature p { font-size: 14.5px; line-height: 1.6; color: var(--muted-on-dark); }
.on-light .feature h4 { color: var(--text-on-light); }
.on-light .feature p { color: var(--muted-on-light); }
.feature .num {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: var(--accent);
  font-variant-numeric: tabular-nums;
}

/* ---------- split layout ---------- */
.split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr);
  gap: clamp(32px, 6vw, 84px);
  align-items: center;
  margin-top: clamp(36px, 6vh, 72px);
}
.split.flip > .stage-copy { order: 2; }
@media (max-width: 940px) {
  .split { grid-template-columns: 1fr; }
  .split.flip > .stage-copy { order: 0; }
}

/* ---------- tech grid ---------- */
.grid-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 16px;
  margin-top: 44px;
}
.card {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  min-height: 300px;
  padding: 26px;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line-dark);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(255, 255, 255, 0.01) 55%, rgba(0, 0, 0, 0.3));
  transition: transform 0.5s var(--ease), border-color 0.5s var(--ease);
}
.card:hover { transform: translateY(-6px); border-color: rgba(255, 255, 255, 0.34); }
.card h3 { font-size: 21px; font-weight: 700; letter-spacing: -0.025em; }
.card p { margin-top: 8px; font-size: 14.5px; color: var(--muted-on-dark); }
.card .more { margin-top: 18px; font-size: 13.5px; font-weight: 600; color: var(--accent); }
.card .glow { position: absolute; inset: auto -20% 40% -20%; height: 220px; border-radius: 50%; filter: blur(70px); opacity: 0.45; z-index: -1; }

/* ---------- company block ---------- */
.facts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1px;
  margin-top: 40px;
  background: var(--line-light);
  border-radius: 18px;
  overflow: hidden;
}
.fact { background: var(--paper); padding: 24px 26px; }
.fact dt { font-size: 12px; letter-spacing: 0.12em; text-transform: uppercase; color: rgba(18, 20, 26, 0.45); }
.fact dd { margin: 8px 0 0; font-size: 16px; font-weight: 600; letter-spacing: -0.015em; color: var(--text-on-light); word-break: break-word; }

/* ---------- footer ---------- */
.site-footer { background: #06070a; border-top: 1px solid var(--line-dark); padding: clamp(48px, 7vh, 84px) var(--gutter) 40px; }
.footer-inner { max-width: var(--maxw); margin: 0 auto; }
.footer-cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 36px; }
.footer-cols h5 { margin: 0 0 16px; font-size: 12px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--faint-on-dark); font-weight: 600; }
.footer-cols li { margin-bottom: 10px; }
.footer-cols a, .footer-cols p { font-size: 14px; color: var(--muted-on-dark); }
.footer-cols a:hover { color: #fff; }
.footer-legal {
  margin-top: 44px;
  padding-top: 22px;
  border-top: 1px solid var(--line-dark);
  display: flex;
  flex-wrap: wrap;
  gap: 8px 26px;
  font-size: 12.5px;
  color: var(--faint-on-dark);
}

/* ---------- scroll reveal ---------- */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity 0.9s var(--ease), transform 0.9s var(--ease); }
.reveal.in { opacity: 1; transform: none; }
.reveal.d1 { transition-delay: 0.08s; }
.reveal.d2 { transition-delay: 0.16s; }
.reveal.d3 { transition-delay: 0.24s; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* ---------- CSS keycap still-life (used where no English screenshot exists) ---------- */
.kb {
  display: grid;
  gap: 10px;
  padding: clamp(18px, 3vw, 30px);
  border-radius: 26px;
  background: linear-gradient(155deg, #1b1f27, #0a0c10 70%);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08), 0 60px 110px -46px rgba(0, 0, 0, 0.85);
}
.kb-row { display: flex; gap: 10px; }
.cap {
  position: relative;
  flex: 1;
  min-width: 30px;
  height: clamp(42px, 5.2vw, 58px);
  border-radius: 13px;
  background: linear-gradient(180deg, #f4f5f7, #d6d9df 64%, #bfc3cb);
  box-shadow: inset 0 -7px 11px rgba(0, 0, 0, 0.17), inset 0 2px 0 rgba(255, 255, 255, 0.92), 0 7px 16px rgba(0, 0, 0, 0.42);
}
.cap::after {
  content: "";
  position: absolute;
  inset: 6px 7px 13px;
  border-radius: 8px;
  background: linear-gradient(180deg, #eceef1, #d1d4da);
}
.cap.warm::after { background: linear-gradient(180deg, #ff8a5c, #e04317); }
.cap.teal::after { background: linear-gradient(180deg, #5ce8d5, #0fa895); }
.cap.ink::after { background: linear-gradient(180deg, #3b414d, #1c2028); }
.cap.wide { flex: 2.4; }
.cap.rocker { flex: 1.5; }
.cap.rocker::after { border-radius: 999px; background: radial-gradient(circle at 38% 32%, #ffffff, #c9ccd3 62%, #9aa0aa); }
.kb-note { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 20px; }
.tag {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.04em;
  padding: 7px 13px;
  border-radius: 999px;
  border: 1px solid var(--line-dark);
  color: var(--muted-on-dark);
  background: rgba(255, 255, 255, 0.04);
}
.on-light .tag { border-color: var(--line-light); color: var(--muted-on-light); background: rgba(10, 11, 13, 0.03); }

/* ---------- legal document pages ---------- */.doc { max-width: 780px; margin: 0 auto; padding: calc(var(--nav-h) + 72px) var(--gutter) 96px; }
.doc h1 { font-size: clamp(32px, 4.6vw, 54px); font-weight: 700; letter-spacing: -0.035em; line-height: 1.05; }
.doc h2 { margin: 44px 0 12px; font-size: 21px; font-weight: 650; letter-spacing: -0.02em; }
.doc p, .doc li { color: var(--muted-on-dark); font-size: 15.5px; }
.doc p + p { margin-top: 14px; }
.doc .updated { margin-top: 14px; font-size: 13px; color: var(--faint-on-dark); letter-spacing: 0.04em; text-transform: uppercase; }
.doc ul { margin: 14px 0 0 18px; }
.doc ul li { list-style: disc; margin-bottom: 8px; }
.doc a { color: var(--accent); }
.doc .panel { margin-top: 40px; padding: 24px 26px; border: 1px solid var(--line-dark); border-radius: 18px; background: rgba(255, 255, 255, 0.03); }

/* Language switch in the top nav */
.lang-switch {
  margin-left: auto;
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  opacity: 0.7;
  white-space: nowrap;
}
.lang-switch:hover { opacity: 1; }

/* Published documents (app-store privacy policies) at the end of a product stage */
.docs {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 0.5rem 1.4rem;
  margin-top: 28px;
  padding-top: 18px;
  border-top: 1px solid var(--line-dark);
  font-size: 0.86rem;
}
.on-light .docs { border-top-color: var(--line-light); }
.docs-label {
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-size: 0.68rem;
  color: var(--muted-on-dark);
}
.on-light .docs-label { color: var(--muted-on-light); }
.docs a {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px solid var(--line-dark);
  padding-bottom: 2px;
}
.on-light .docs a { border-bottom-color: var(--line-light); }
.docs a:hover { color: var(--accent-teal); border-bottom-color: var(--accent-teal); }
