/* CarMoji landing page — dark, warm, glowing like the Classic shell. */

:root {
  --bg: #0d0a07;
  --bg-2: #16110b;
  --panel: #1d1710;
  --text: #f5ecdd;
  --muted: #b7a98e;
  --amber: #ffc75c;
  --cyan: #45e8ff;
  --pink: #ff8cb3;
  --green: #7ed99a;
  --radius: 20px;
  --font: "Nunito", ui-rounded, -apple-system, "SF Pro Rounded",
          "PingFang SC", "Hiragino Sans GB", sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  line-height: 1.6;
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

/* ---------- nav ---------- */
nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(13,10,7,0.8);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.nav-inner {
  max-width: 1080px; margin: 0 auto; padding: 12px 24px;
  display: flex; align-items: center; justify-content: space-between;
}
.brand { display: flex; align-items: center; gap: 10px; font-weight: 900; font-size: 18px; }
.brand img { width: 32px; border-radius: 8px; }
.nav-links { display: flex; align-items: center; gap: 20px; font-size: 14px; font-weight: 700; }
.nav-links a { opacity: 0.8; }
.nav-links a:hover { opacity: 1; }
#lang-toggle {
  font: inherit; font-weight: 800; color: var(--amber);
  background: rgba(255,199,92,0.12);
  border: 1px solid rgba(255,199,92,0.35);
  border-radius: 999px; padding: 4px 14px; cursor: pointer;
}
#lang-toggle:hover { background: rgba(255,199,92,0.22); }

/* ---------- hero ---------- */
.hero {
  position: relative;
  max-width: 1080px; margin: 0 auto;
  padding: 80px 24px 0;
  display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 40px;
  align-items: center; overflow: visible;
}
.hero-glow {
  position: absolute; top: 10%; right: -10%;
  width: 640px; height: 640px; border-radius: 50%;
  background: radial-gradient(circle, rgba(255,199,92,0.28), transparent 70%);
  pointer-events: none;
}
.kicker {
  font-size: 13px; letter-spacing: 0.25em; text-transform: uppercase;
  font-weight: 800; color: var(--amber); margin-bottom: 10px;
}
.kicker.cyan { color: var(--cyan); }
.kicker.pink { color: var(--pink); }
.kicker.green { color: var(--green); }
.kicker.amber { color: var(--amber); }
.hero h1 { font-size: clamp(40px, 6vw, 64px); line-height: 1.05; font-weight: 900; }
.hero .sub { margin-top: 18px; color: var(--muted); font-size: 18px; max-width: 34em; }
.cta-row { display: flex; gap: 14px; margin-top: 28px; flex-wrap: wrap; }
.cta {
  font-weight: 800; font-size: 15px;
  padding: 12px 22px; border-radius: 999px;
}
.cta.appstore { background: var(--amber); color: #241a08; }
.cta.appstore:hover { filter: brightness(1.08); }
.cta.ghost { border: 1px solid rgba(255,255,255,0.25); }
.cta.ghost:hover { border-color: rgba(255,255,255,0.5); }

/* ---------- phone frame ---------- */
.phone { position: relative; width: min(320px, 80vw); margin: 0 auto; }
.phone .frame { position: relative; z-index: 1; pointer-events: none; }
.phone .screen {
  position: absolute; z-index: 2;
  left: 5.09%; top: 2.21%; width: 89.82%; height: 95.58%;
  border-radius: 13.7% / 6.3%;
  overflow: hidden; background: #000;
}
.phone .screen img { width: 100%; height: 100%; object-fit: cover; object-position: top; }
.hero-phone { filter: drop-shadow(0 30px 60px rgba(0,0,0,0.7)); transform: translateY(24px); }
.tilt-l { transform: rotate(-4deg); }
.tilt-r { transform: rotate(4deg); }

/* ---------- features ---------- */
main { max-width: 1080px; margin: 0 auto; padding: 0 24px; }
.feature {
  display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 48px;
  align-items: center; padding: 110px 0;
  opacity: 0; transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.feature.visible, .souls.visible { opacity: 1; transform: none; }
.feature.reverse { grid-template-columns: 0.9fr 1.1fr; }
.feature.reverse .feature-text { order: 2; }
.feature.reverse .phone { order: 1; }
.feature h2, .souls h2 { font-size: clamp(30px, 4vw, 44px); font-weight: 900; line-height: 1.1; }
.feature p { margin-top: 14px; color: var(--muted); font-size: 17px; }
.feature ul { margin-top: 16px; color: var(--muted); padding-left: 1.2em; }
.feature li { margin-top: 6px; }
.feature li::marker { color: var(--amber); }

/* ---------- souls ---------- */
.souls {
  text-align: center; padding: 110px 0;
  opacity: 0; transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.center-sub { color: var(--muted); margin-top: 12px; }
.souls-row {
  margin-top: 44px;
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px;
}
.phone.mini { width: 100%; }
.souls-row .phone:nth-child(2) { transform: translateY(-14px); }
.souls-row .phone:nth-child(3) { transform: translateY(-28px); }
.souls-row .phone:nth-child(4) { transform: translateY(-14px); }

/* ---------- terminal ---------- */
.terminal {
  margin-top: 22px; position: relative;
  background: #120d09; border: 1px solid rgba(255,255,255,0.1);
  border-radius: 14px; overflow: hidden;
  font-size: 14px;
}
.term-bar { display: flex; gap: 6px; padding: 10px 12px; }
.term-bar span { width: 10px; height: 10px; border-radius: 50%; background: rgba(255,255,255,0.15); }
.terminal pre { padding: 4px 16px 16px; overflow-x: auto; }
.terminal code { font-family: ui-monospace, "SF Mono", Menlo, monospace; color: #ffe9c4; }
.terminal em { color: var(--muted); font-style: normal; }
.copy {
  position: absolute; top: 8px; right: 10px;
  font: inherit; font-weight: 700; font-size: 12px;
  color: var(--amber); background: rgba(255,199,92,0.12);
  border: 1px solid rgba(255,199,92,0.3); border-radius: 8px;
  padding: 3px 10px; cursor: pointer;
}

/* ---------- footer ---------- */
footer {
  border-top: 1px solid rgba(255,255,255,0.06);
  margin-top: 40px; padding: 56px 24px 72px;
  text-align: center; color: var(--muted);
}
footer img { width: 48px; border-radius: 12px; margin: 0 auto 14px; }
footer .fine { margin-top: 10px; font-size: 13px; opacity: 0.7; }
footer a { text-decoration: underline; }

/* ---------- responsive ---------- */
@media (max-width: 820px) {
  .hero { grid-template-columns: 1fr; padding-top: 48px; text-align: center; }
  .hero .sub { margin-inline: auto; }
  .cta-row { justify-content: center; }
  .feature, .feature.reverse { grid-template-columns: 1fr; gap: 32px; padding: 70px 0; }
  .feature.reverse .feature-text { order: 1; }
  .feature.reverse .phone { order: 2; }
  .souls-row { grid-template-columns: repeat(2, 1fr); }
  .souls-row .phone { transform: none !important; }
}

/* Chinese: looser tracking hurts CJK — tighten kickers. */
html[lang="zh-Hans"] .kicker { letter-spacing: 0.12em; }
html[lang="zh-Hans"] body, html[lang="zh-Hans"] { line-height: 1.75; }
