/* Soaring Xuanyuan — static developer site */
:root {
  --bg: #0f1013;
  --bg-soft: #16181d;
  --card: #1c1f26;
  --line: #2a2e37;
  --text: #eceef2;
  --muted: #a2a9b6;
  --accent: #c9a227;
  --accent-2: #7f5af0;
  --radius: 16px;
  --max: 1080px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.65 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

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

a { color: inherit; }

.wrap {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 20px;
}

/* ---------- header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(15, 16, 19, .88);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: 62px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  letter-spacing: .2px;
  text-decoration: none;
}

.brand img { width: 30px; height: 30px; border-radius: 8px; }

.nav { display: flex; gap: 22px; font-size: 15px; }

.nav a {
  color: var(--muted);
  text-decoration: none;
}

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

/* ---------- hero ---------- */
.hero {
  background:
    radial-gradient(900px 420px at 15% -10%, rgba(127, 90, 240, .28), transparent 60%),
    radial-gradient(700px 380px at 90% 0%, rgba(201, 162, 39, .18), transparent 60%),
    var(--bg-soft);
  border-bottom: 1px solid var(--line);
  padding: 44px 0 30px;
}

.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* ---------- app carousel ---------- */
.carousel { position: relative; }

.track {
  display: flex;
  gap: 24px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  padding: 4px 0 8px;
}

.track::-webkit-scrollbar { display: none; }

.slide {
  flex: 0 0 100%;
  scroll-snap-align: start;
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  gap: 32px;
  align-items: center;
  min-width: 0;
}

.slide > * { min-width: 0; }

.slide-title {
  font-size: clamp(28px, 4.6vw, 44px);
  line-height: 1.15;
  letter-spacing: -.5px;
  margin: 0 0 12px;
}

.slide-art {
  display: flex;
  justify-content: center;
  gap: 14px;
  min-width: 0;
}

.slide-art img {
  width: calc((100% - 14px) / 2);
  max-width: 190px;
  border-radius: 22px;
  border: 1px solid var(--line);
  box-shadow: 0 18px 44px rgba(0, 0, 0, .5);
}

.slide-art img:first-child { transform: rotate(-1.5deg); }
.slide-art img:last-child { transform: rotate(1.5deg); }

.nav-btn {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: rgba(15, 16, 19, .78);
  color: var(--text);
  font-size: 17px;
  line-height: 1;
  cursor: pointer;
  display: grid;
  place-items: center;
  padding: 0;
}

.nav-btn:hover { border-color: var(--muted); }

.carousel-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 14px 20px;
  margin-top: 20px;
}

.dots {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 7px;
}

.dots button {
  width: 8px;
  height: 8px;
  padding: 0;
  border-radius: 50%;
  border: 0;
  background: var(--line);
  cursor: pointer;
}

.dots button[aria-current="true"] { background: var(--accent); transform: scale(1.35); }

.btn.play::before {
  content: "";
  width: 0;
  height: 0;
  border-left: 11px solid currentColor;
  border-top: 7px solid transparent;
  border-bottom: 7px solid transparent;
}

.carousel-note {
  text-align: center;
  color: var(--muted);
  font-size: 13px;
  margin: 14px 0 0;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .track { scroll-behavior: auto; }
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: .14em;
  font-size: 12px;
  color: var(--accent);
  margin: 0 0 14px;
}

h1 {
  font-size: clamp(30px, 5vw, 46px);
  line-height: 1.15;
  margin: 0 0 14px;
  letter-spacing: -.5px;
}

.lede {
  color: var(--muted);
  font-size: 17px;
  margin: 0 0 26px;
  max-width: 46ch;
}

.app-row {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 22px;
}

.app-row img {
  width: 68px;
  height: 68px;
  border-radius: 18px;
  box-shadow: 0 8px 26px rgba(0, 0, 0, .45);
}

.app-row strong { display: block; font-size: 20px; }

.app-row span { color: var(--muted); font-size: 14px; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 12px 20px;
  border-radius: 999px;
  background: var(--text);
  color: #12131a;
  font-weight: 650;
  text-decoration: none;
  border: 1px solid transparent;
}

.btn:hover { transform: translateY(-1px); }

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

.btn.ghost:hover { border-color: var(--muted); }

.btn + .btn { margin-left: 10px; }

.badge-note {
  margin: 16px 0 0;
  font-size: 13px;
  color: var(--muted);
}

/* ---------- sections ---------- */
section { padding: 60px 0; }

/* keep anchor targets clear of the sticky header */
main[id], section[id] { scroll-margin-top: 78px; }

h2 {
  font-size: clamp(22px, 3.2vw, 30px);
  margin: 0 0 6px;
  letter-spacing: -.3px;
}

.section-sub {
  color: var(--muted);
  margin: 0 0 28px;
  max-width: 62ch;
}

/* ---------- features ---------- */
.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 16px;
}

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

.card h3 { margin: 0 0 8px; font-size: 17px; }

.card p { margin: 0; color: var(--muted); font-size: 15px; }

.card .dot {
  display: inline-block;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  margin-bottom: 14px;
  background: linear-gradient(140deg, var(--accent-2), var(--accent));
}

/* ---------- apps grid ---------- */
.apps {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 14px;
}

.app-card {
  display: block;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px;
  text-decoration: none;
  transition: border-color .18s, transform .18s;
}

.app-card:hover {
  border-color: #46506a;
  transform: translateY(-2px);
}

.app-card img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 14px;
  margin-bottom: 12px;
  background: var(--bg-soft);
}

.app-card span { display: block; font-size: 14px; font-weight: 600; line-height: 1.35; }

.app-card small { color: var(--muted); font-size: 12px; }

/* ---------- about / contact ---------- */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 32px;
  align-items: start;
}

dl { margin: 0; }

dt {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .1em;
  color: var(--accent);
  margin-top: 18px;
}

dd { margin: 4px 0 0; color: var(--muted); }

dd a { color: var(--text); }

/* ---------- footer ---------- */
.site-footer {
  border-top: 1px solid var(--line);
  background: var(--bg-soft);
  padding: 30px 0 40px;
  font-size: 14px;
  color: var(--muted);
}

.site-footer .wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 26px;
  justify-content: space-between;
}

.site-footer nav { display: flex; gap: 20px; }

.site-footer a { color: var(--muted); text-decoration: none; }

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

/* ---------- legal page ---------- */
.legal { padding: 52px 0 72px; }

.legal h1 { font-size: clamp(26px, 4vw, 36px); }

.legal h2 { margin-top: 36px; font-size: 20px; }

.legal p, .legal li { color: var(--muted); max-width: 74ch; }

.legal ul { padding-left: 22px; }

.legal .updated { color: var(--accent); font-size: 14px; }

/* ---------- responsive ---------- */
@media (max-width: 860px) {
  .split { grid-template-columns: 1fr; }
  .slide { grid-template-columns: 1fr; gap: 22px; }
  .slide-art { margin-top: 4px; }
  .slide-art img { transform: none !important; max-width: 160px; }
  .nav { display: none; }
  .carousel-bar { gap: 10px 10px; flex-wrap: nowrap; }
  .dots { gap: 4px; flex: 1 1 auto; min-width: 0; }
  .dots button { width: 6px; height: 6px; }
  section { padding: 44px 0; }
  .btn + .btn { margin: 10px 0 0; }
  .btn { width: 100%; justify-content: center; }
}
