:root {
  --bg-deep: #06080f;
  --bg-card: rgba(18, 24, 38, 0.72);
  --bg-card-hover: rgba(28, 38, 58, 0.85);
  --border: rgba(120, 160, 255, 0.12);
  --text: #e8edf7;
  --text-muted: #8b95a8;
  --accent: #4f8cff;
  --accent-2: #2ee6d6;
  --accent-glow: rgba(79, 140, 255, 0.35);
  --radius: 16px;
  --font-sans: 'DM Sans', 'Noto Sans SC', system-ui, sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  min-height: 100%;
  font-family: var(--font-sans);
  background: var(--bg-deep);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
  text-decoration: none;
}

img {
  max-width: 100%;
  display: block;
}

ul {
  list-style: none;
}

/* Background */
.bg-grid {
  position: fixed;
  inset: 0;
  z-index: -2;
  background:
    radial-gradient(ellipse 80% 50% at 50% -20%, rgba(79, 140, 255, 0.22), transparent),
    radial-gradient(ellipse 60% 40% at 100% 50%, rgba(46, 230, 214, 0.08), transparent),
    radial-gradient(ellipse 50% 30% at 0% 80%, rgba(79, 140, 255, 0.1), transparent),
    var(--bg-deep);
}

.bg-grid::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image: linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 64px 64px;
  mask-image: radial-gradient(ellipse 70% 60% at 50% 30%, black, transparent);
  pointer-events: none;
}

.wrap {
  width: min(1120px, 92vw);
  margin-inline: auto;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(14px);
  background: rgba(6, 8, 15, 0.75);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
  width: min(1120px, 92vw);
  margin-inline: auto;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.15rem;
  letter-spacing: -0.02em;
}

.logo-mark {
  width: 36px;
  height: 36px;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  display: grid;
  place-items: center;
  box-shadow: 0 0 24px var(--accent-glow);
}

.logo-mark svg {
  width: 22px;
  height: 22px;
  color: #061018;
}

.nav-main {
  display: flex;
  align-items: center;
  gap: 28px;
}

.nav-main a {
  font-size: 0.92rem;
  color: var(--text-muted);
  transition: color 0.2s;
}

.nav-main a:hover {
  color: var(--text);
}

.nav-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: 999px;
  font-size: 0.9rem;
  font-weight: 600;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform 0.15s, box-shadow 0.2s, background 0.2s;
}

.btn:active {
  transform: scale(0.98);
}

.btn-ghost {
  border-color: var(--border);
  background: transparent;
  color: var(--text);
}

.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.05);
}

.btn-primary {
  background: linear-gradient(135deg, var(--accent), #6b5cff);
  color: #fff;
  box-shadow: 0 8px 28px var(--accent-glow);
}

.btn-primary:hover {
  box-shadow: 0 10px 36px rgba(79, 140, 255, 0.45);
}

.nav-toggle {
  display: none;
  width: 40px;
  height: 40px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: transparent;
  color: var(--text);
  cursor: pointer;
}

/* Hero */
.hero {
  padding: 72px 0 88px;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 48px;
  align-items: center;
}

@media (max-width: 900px) {
  .hero-grid {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .hero-ctas {
    justify-content: center;
  }

  .nav-main,
  .nav-actions .btn-ghost {
    display: none;
  }

  .nav-toggle {
    display: grid;
    place-items: center;
  }

  .nav-main.is-open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    padding: 20px 4vw 24px;
    background: rgba(6, 8, 15, 0.96);
    border-bottom: 1px solid var(--border);
    gap: 16px;
  }
}

.eyebrow {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--accent-2);
  margin-bottom: 14px;
}

.hero h1 {
  font-size: clamp(2rem, 4vw, 2.85rem);
  line-height: 1.15;
  letter-spacing: -0.03em;
  margin-bottom: 16px;
}

.hero-lead {
  font-size: 1.05rem;
  color: var(--text-muted);
  max-width: 34ch;
  margin-bottom: 28px;
}

@media (max-width: 900px) {
  .hero-lead {
    margin-inline: auto;
  }
}

.hero-ctas {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.hero-visual {
  position: relative;
  min-height: 320px;
}

.device-frame {
  position: absolute;
  inset: 0 auto auto 50%;
  transform: translateX(-50%);
  width: min(420px, 100%);
  aspect-ratio: 4/3;
  border-radius: 20px;
  background: linear-gradient(145deg, rgba(30, 40, 60, 0.9), rgba(12, 16, 28, 0.95));
  border: 1px solid var(--border);
  box-shadow:
    0 40px 80px rgba(0, 0, 0, 0.45),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
  overflow: hidden;
}

.device-screen {
  position: absolute;
  inset: 12px;
  border-radius: 12px;
  background: linear-gradient(160deg, rgba(79, 140, 255, 0.15), transparent 55%),
    linear-gradient(0deg, #0c1018, #121a28);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
}

.pulse-dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--accent-2);
  box-shadow: 0 0 0 0 rgba(46, 230, 214, 0.5);
  animation: pulse 2.2s ease-out infinite;
}

@keyframes pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(46, 230, 214, 0.45);
  }
  70% {
    box-shadow: 0 0 0 18px rgba(46, 230, 214, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(46, 230, 214, 0);
  }
}

.screen-label {
  font-size: 0.85rem;
  color: var(--text-muted);
}

.orb {
  position: absolute;
  width: 200px;
  height: 200px;
  border-radius: 50%;
  background: radial-gradient(circle, var(--accent-glow), transparent 70%);
  filter: blur(8px);
  right: -40px;
  bottom: -20px;
  pointer-events: none;
}

/* Feature strip */
.features-strip {
  padding: 24px 0 56px;
}

.features-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
}

.feature-pill {
  padding: 20px 22px;
  border-radius: var(--radius);
  background: var(--bg-card);
  border: 1px solid var(--border);
  text-align: center;
  transition: background 0.2s, border-color 0.2s;
}

.feature-pill:hover {
  background: var(--bg-card-hover);
  border-color: rgba(79, 140, 255, 0.25);
}

.feature-pill h3 {
  font-size: 1rem;
  margin-bottom: 6px;
}

.feature-pill p {
  font-size: 0.88rem;
  color: var(--text-muted);
}

/* Section */
.section {
  padding: 56px 0;
}

.section-head {
  text-align: center;
  max-width: 560px;
  margin: 0 auto 40px;
}

.section-head h2 {
  font-size: clamp(1.5rem, 3vw, 2rem);
  letter-spacing: -0.02em;
  margin-bottom: 10px;
}

.section-head p {
  color: var(--text-muted);
  font-size: 0.98rem;
}

/* App grid */
.app-chips {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 10px;
}

.app-chip {
  padding: 10px 16px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border);
  font-size: 0.88rem;
  color: var(--text-muted);
}

/* Intro blocks */
.intro-grid {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.intro-card {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 24px;
  align-items: start;
  padding: 28px;
  border-radius: var(--radius);
  background: var(--bg-card);
  border: 1px solid var(--border);
}

@media (max-width: 640px) {
  .intro-card {
    grid-template-columns: 1fr;
  }
}

.intro-icon {
  width: 48px;
  height: 48px;
  border-radius: 14px;
  background: linear-gradient(135deg, rgba(79, 140, 255, 0.25), rgba(46, 230, 214, 0.12));
  display: grid;
  place-items: center;
  font-size: 1.35rem;
}

.intro-card h3 {
  font-size: 1.1rem;
  margin-bottom: 8px;
}

.intro-card p {
  font-size: 0.95rem;
  color: var(--text-muted);
}

/* Reviews */
.reviews {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

@media (max-width: 900px) {
  .reviews {
    grid-template-columns: 1fr;
  }
}

.review-card {
  padding: 22px;
  border-radius: var(--radius);
  background: var(--bg-card);
  border: 1px solid var(--border);
}

.review-text {
  font-size: 0.95rem;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.review-meta {
  font-size: 0.85rem;
  color: var(--text);
  font-weight: 600;
}

.stars {
  color: #fbbf24;
  letter-spacing: 2px;
  margin-bottom: 10px;
  font-size: 0.9rem;
}

/* Download */
.download-grid {
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 32px;
  align-items: start;
}

@media (max-width: 800px) {
  .download-grid {
    grid-template-columns: 1fr;
  }
}

.download-btns {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

@media (max-width: 480px) {
  .download-btns {
    grid-template-columns: 1fr;
  }
}

.download-btns .btn {
  width: 100%;
  justify-content: flex-start;
  border-radius: 14px;
  padding: 14px 18px;
}

.download-btns .btn span {
  display: block;
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--text-muted);
}

.qr-panel {
  padding: 24px;
  border-radius: var(--radius);
  background: var(--bg-card);
  border: 1px solid var(--border);
  text-align: center;
}

.qr-panel h4 {
  font-size: 0.95rem;
  margin-bottom: 6px;
}

.qr-panel p {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 16px;
}

.qr-placeholder {
  width: 160px;
  height: 160px;
  margin: 0 auto;
  border-radius: 12px;
  background: repeating-linear-gradient(
      45deg,
      rgba(255, 255, 255, 0.04),
      rgba(255, 255, 255, 0.04) 8px,
      rgba(255, 255, 255, 0.08) 8px,
      rgba(255, 255, 255, 0.08) 16px
    );
  border: 1px dashed var(--border);
  display: grid;
  place-items: center;
  font-size: 0.75rem;
  color: var(--text-muted);
  padding: 12px;
}

.invite-banner {
  margin-top: 20px;
  padding: 12px 16px;
  border-radius: 12px;
  background: rgba(79, 140, 255, 0.1);
  border: 1px solid rgba(79, 140, 255, 0.2);
  font-size: 0.85rem;
  display: none;
}

.invite-banner.is-visible {
  display: block;
}

.invite-banner code {
  font-family: ui-monospace, monospace;
  color: var(--accent-2);
}

/* Plans */
.plans-scroll {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 12px;
}

@media (max-width: 1100px) {
  .plans-scroll {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 640px) {
  .plans-scroll {
    grid-template-columns: 1fr 1fr;
  }
}

.plan-card {
  padding: 20px 16px;
  border-radius: var(--radius);
  background: var(--bg-card);
  border: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  min-height: 100%;
  transition: transform 0.2s, border-color 0.2s;
}

.plan-card:hover {
  transform: translateY(-3px);
  border-color: rgba(79, 140, 255, 0.35);
}

.plan-card.is-featured {
  border-color: rgba(46, 230, 214, 0.4);
  box-shadow: 0 0 0 1px rgba(46, 230, 214, 0.15);
}

.plan-label {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--accent-2);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  min-height: 1.2em;
  margin-bottom: 6px;
}

.plan-name {
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 10px;
}

.plan-price {
  font-size: 1.65rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 4px;
}

.plan-price small {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--text-muted);
}

.plan-original {
  font-size: 0.8rem;
  color: var(--text-muted);
  text-decoration: line-through;
  margin-bottom: 14px;
  min-height: 1.2em;
}

.plan-list {
  flex: 1;
  margin-bottom: 16px;
}

.plan-list li {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-bottom: 6px;
  line-height: 1.45;
}

.plan-list li.is-strong {
  color: var(--text);
  font-weight: 600;
}

.plan-card .btn-primary {
  width: 100%;
  font-size: 0.82rem;
  padding: 10px;
}

/* Footer */
.site-footer {
  margin-top: 48px;
  padding: 48px 0 32px;
  border-top: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.25);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr 1fr;
  gap: 32px;
  margin-bottom: 36px;
}

@media (max-width: 800px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 480px) {
  .footer-grid {
    grid-template-columns: 1fr;
  }
}

.footer-brand p {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-top: 10px;
  max-width: 280px;
}

.footer-col h4 {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin-bottom: 14px;
}

.footer-col a {
  display: block;
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 10px;
}

.footer-col a:hover {
  color: var(--text);
}

.footer-bottom {
  padding-top: 24px;
  border-top: 1px solid var(--border);
  font-size: 0.82rem;
  color: var(--text-muted);
  text-align: center;
}

/* Auth (login / register) — 对接 api.md /api/auth/* */
.auth-main {
  min-height: calc(100vh - 64px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 16px 64px;
}

.auth-card {
  width: min(400px, 100%);
  padding: 32px 28px;
  border-radius: var(--radius);
  background: var(--bg-card);
  border: 1px solid var(--border);
  box-shadow: 0 24px 48px rgba(0, 0, 0, 0.35);
}

.auth-card h1 {
  font-size: 1.35rem;
  margin-bottom: 8px;
  letter-spacing: -0.02em;
}

.auth-lead {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 24px;
}

.auth-lead a {
  color: var(--accent);
}

.auth-lead a:hover {
  text-decoration: underline;
}

.form-field {
  margin-bottom: 16px;
}

.form-field label {
  display: block;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 6px;
}

.form-field input {
  width: 100%;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: rgba(0, 0, 0, 0.25);
  color: var(--text);
  font-size: 1rem;
  font-family: inherit;
}

.form-field input:focus {
  outline: none;
  border-color: rgba(79, 140, 255, 0.5);
  box-shadow: 0 0 0 3px var(--accent-glow);
}

.form-field input::placeholder {
  color: rgba(139, 149, 168, 0.7);
}

.form-actions {
  margin-top: 24px;
}

.form-actions .btn-primary {
  width: 100%;
  padding: 12px;
}

.form-error {
  font-size: 0.88rem;
  color: #f87171;
  margin-bottom: 12px;
  min-height: 1.25em;
}

.form-error:empty {
  display: none;
}

.form-success {
  font-size: 0.88rem;
  color: var(--accent-2);
  margin-bottom: 12px;
}

button.btn-primary:disabled {
  opacity: 0.65;
  cursor: not-allowed;
  transform: none;
}
