/* 琉璃AI Design System */
:root {
  --primary: #7c3aed;
  --primary-deep: #4f46e5;
  --accent: #f97316;
  --bg: #0f0f1a;
  --bg-mid: #1a1035;
  --surface: rgba(255, 255, 255, 0.04);
  --surface-strong: rgba(255, 255, 255, 0.07);
  --border: rgba(255, 255, 255, 0.08);
  --border-strong: rgba(255, 255, 255, 0.14);
  --text: #f5f5f7;
  --text-muted: #a1a1aa;
  --text-dim: #71717a;
  --success: #22c55e;
  --warning: #f59e0b;
  --danger: #ef4444;
  --grad: linear-gradient(135deg, var(--primary), var(--primary-deep));
  --grad-cta: linear-gradient(135deg, var(--accent), #fb923c);
  --shadow: 0 20px 50px rgba(124, 58, 237, 0.15);
  --shadow-lg: 0 30px 80px rgba(124, 58, 237, 0.22);
  --radius-card: 16px;
  --radius-btn: 12px;
  --radius-input: 12px;
  --nav-h: 72px;
  --font: "PingFang SC", "Microsoft YaHei", "Noto Sans SC", Inter, system-ui, -apple-system, sans-serif;
  --max: 1180px;
}

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

html {
  scroll-behavior: smooth;
}

html,
body {
  min-height: 100%;
}

body {
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

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

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

button,
input,
textarea,
select {
  font: inherit;
  color: inherit;
}

button {
  cursor: pointer;
  border: none;
  background: none;
}

ul,
ol {
  list-style: none;
}

/* scrollbar */
::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}
::-webkit-scrollbar-track {
  background: rgba(255, 255, 255, 0.03);
}
::-webkit-scrollbar-thumb {
  background: rgba(124, 58, 237, 0.45);
  border-radius: 99px;
  border: 2px solid transparent;
  background-clip: content-box;
}
::-webkit-scrollbar-thumb:hover {
  background: rgba(124, 58, 237, 0.7);
  border: 2px solid transparent;
  background-clip: content-box;
}

/* Animated background */
.bg-root {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  overflow: hidden;
  background: linear-gradient(135deg, #0f0f1a 0%, #1a1035 100%);
}

.bg-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  will-change: transform;
  transform: translate3d(0, 0, 0);
}

.bg-grid {
  position: absolute;
  inset: 0;
  opacity: 0.035;
  background-image: radial-gradient(rgba(255, 255, 255, 0.9) 1px, transparent 1px);
  background-size: 28px 28px;
}

.noise {
  position: absolute;
  inset: 0;
  opacity: 0.04;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 200 200' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 180px 180px;
  mix-blend-mode: overlay;
}

/* Layout */
.container {
  width: min(100% - 40px, var(--max));
  margin-inline: auto;
}

.section {
  padding: 100px 0;
}

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

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid rgba(124, 58, 237, 0.35);
  background: rgba(124, 58, 237, 0.12);
  color: #c4b5fd;
  font-size: 13px;
  margin-bottom: 18px;
}

.h1 {
  font-size: clamp(36px, 6vw, 64px);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.02em;
}

.h2 {
  font-size: clamp(28px, 4vw, 40px);
  font-weight: 750;
  line-height: 1.2;
  letter-spacing: -0.01em;
}

.h3 {
  font-size: 20px;
  font-weight: 700;
}

.lead {
  color: var(--text-muted);
  font-size: 17px;
  margin-top: 16px;
}

.grad-text {
  background: linear-gradient(120deg, #c4b5fd, #818cf8 45%, #fb923c);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* Nav */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  transition: background 0.3s ease, border-color 0.3s ease, backdrop-filter 0.3s ease;
  border-bottom: 1px solid transparent;
}

.nav.is-scrolled {
  background: rgba(15, 15, 26, 0.72);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom-color: var(--border);
}

.nav-inner {
  width: min(100% - 40px, var(--max));
  margin-inline: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

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

.logo-mark {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: var(--grad);
  display: grid;
  place-items: center;
  box-shadow: 0 8px 24px rgba(124, 58, 237, 0.4);
  font-size: 14px;
  font-weight: 800;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
  color: var(--text-muted);
  font-size: 14px;
}

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

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

.nav-toggle {
  display: none;
  width: 40px;
  height: 40px;
  border-radius: 10px;
  border: 1px solid var(--border);
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 5px;
}

.nav-toggle span {
  display: block;
  width: 16px;
  height: 1.5px;
  background: var(--text);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 0 20px;
  border-radius: var(--radius-btn);
  font-weight: 600;
  font-size: 14px;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, border-color 0.2s ease, color 0.2s ease;
  white-space: nowrap;
  user-select: none;
}

.btn:hover {
  transform: scale(1.02);
}

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

.btn-primary {
  background: var(--grad);
  color: white;
  box-shadow: 0 10px 30px rgba(124, 58, 237, 0.35);
}

.btn-primary:hover {
  box-shadow: 0 14px 40px rgba(124, 58, 237, 0.5);
}

.btn-accent {
  background: var(--grad-cta);
  color: #1a0f05;
  box-shadow: 0 10px 30px rgba(249, 115, 22, 0.35);
}

.btn-ghost {
  border: 1px solid var(--border-strong);
  background: rgba(255, 255, 255, 0.03);
  color: var(--text);
}

.btn-ghost:hover {
  border-color: rgba(124, 58, 237, 0.5);
  background: rgba(124, 58, 237, 0.1);
}

.btn-lg {
  min-height: 52px;
  padding: 0 28px;
  font-size: 16px;
  border-radius: 14px;
}

.btn-block {
  width: 100%;
}

.btn[disabled] {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none !important;
}

.btn-loading .btn-label {
  opacity: 0;
}

.btn-loading::after {
  content: "";
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, 0.25);
  border-top-color: white;
  animation: spin 0.7s linear infinite;
  position: absolute;
}

.btn {
  position: relative;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* Cards */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-card);
  padding: 24px;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease, background 0.25s ease;
}

.card:hover {
  transform: translateY(-4px);
  border-color: rgba(124, 58, 237, 0.35);
  box-shadow: var(--shadow);
  background: var(--surface-strong);
}

/* Forms */
.field {
  display: grid;
  gap: 8px;
  margin-bottom: 16px;
}

.field label {
  font-size: 13px;
  color: var(--text-muted);
  font-weight: 500;
}

.input,
.textarea,
.select {
  width: 100%;
  min-height: 46px;
  padding: 12px 14px;
  border-radius: var(--radius-input);
  border: 1px solid var(--border-strong);
  background: rgba(255, 255, 255, 0.03);
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.textarea {
  min-height: 110px;
  resize: vertical;
}

.input:focus,
.textarea:focus,
.select:focus {
  border-color: rgba(124, 58, 237, 0.7);
  box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.18), 0 0 24px rgba(124, 58, 237, 0.15);
}

.input::placeholder,
.textarea::placeholder {
  color: var(--text-dim);
}

.field-error {
  color: #fca5a5;
  font-size: 12px;
  min-height: 16px;
}

/* Toast */
.toast-wrap {
  position: fixed;
  top: 24px;
  right: 24px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
}

.toast {
  pointer-events: auto;
  min-width: 220px;
  max-width: 340px;
  padding: 14px 16px;
  border-radius: 14px;
  background: rgba(24, 24, 38, 0.92);
  border: 1px solid var(--border-strong);
  backdrop-filter: blur(12px);
  box-shadow: var(--shadow);
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
}

.toast.success .toast-icon {
  color: var(--success);
}
.toast.error .toast-icon {
  color: var(--danger);
}

/* Modal */
.modal-backdrop {
  position: fixed;
  inset: 0;
  z-index: 200;
  background: rgba(8, 8, 16, 0.72);
  backdrop-filter: blur(8px);
  display: grid;
  place-items: center;
  padding: 24px;
  opacity: 0;
  visibility: hidden;
}

.modal-backdrop.is-open {
  opacity: 1;
  visibility: visible;
}

.modal {
  width: min(100%, 520px);
  background: rgba(22, 18, 40, 0.96);
  border: 1px solid rgba(124, 58, 237, 0.35);
  border-radius: 20px;
  padding: 28px;
  box-shadow: var(--shadow-lg);
  transform: scale(0.9);
  opacity: 0;
}

.modal-backdrop.is-open .modal {
  transform: scale(1);
  opacity: 1;
  transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.25s ease;
}

/* Skeleton shimmer */
.skeleton {
  position: relative;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 10px;
  height: 14px;
  margin-bottom: 10px;
}

.skeleton::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.08), transparent);
  transform: translateX(-100%);
  animation: shimmer 1.4s infinite;
}

@keyframes shimmer {
  100% {
    transform: translateX(100%);
  }
}

/* Marquee */
.marquee {
  overflow: hidden;
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}

.marquee-track {
  display: flex;
  gap: 18px;
  width: max-content;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* Responsive nav */
@media (max-width: 860px) {
  .nav-links,
  .nav-actions .btn-ghost {
    display: none;
  }

  .nav-toggle {
    display: inline-flex;
  }

  .nav.is-open .nav-links {
    display: flex;
    position: absolute;
    top: var(--nav-h);
    left: 0;
    right: 0;
    flex-direction: column;
    gap: 0;
    background: rgba(15, 15, 26, 0.96);
    border-bottom: 1px solid var(--border);
    padding: 12px 20px 20px;
  }

  .nav.is-open .nav-links a {
    padding: 14px 0;
    border-bottom: 1px solid var(--border);
  }

  .section {
    padding: 72px 0;
  }
}

/* Word split helpers */
.word {
  display: inline-block;
  will-change: transform, opacity, filter;
}

/* Pulse glow for CTA */
.pulse-glow {
  animation: pulseGlow 2.2s ease-in-out infinite;
}

@keyframes pulseGlow {
  0%,
  100% {
    box-shadow: 0 10px 30px rgba(124, 58, 237, 0.35);
  }
  50% {
    box-shadow: 0 12px 40px rgba(124, 58, 237, 0.65), 0 0 0 8px rgba(124, 58, 237, 0.08);
  }
}

.float-y {
  animation: floatY 4.5s ease-in-out infinite;
}

@keyframes floatY {
  0%,
  100% {
    transform: translateY(-10px);
  }
  50% {
    transform: translateY(10px);
  }
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}
