:root {
  --bg: #f5f5f7;
  --surface: #ffffff;
  --surface-soft: rgba(255,255,255,.72);
  --text: #1d1d1f;
  --muted: #6e6e73;
  --muted-2: #86868b;
  --line: rgba(0,0,0,.08);
  --blue: #0071e3;
  --purple: #7857ff;
  --shadow: 0 30px 100px rgba(0,0,0,.08);
  --radius-xl: 34px;
  --radius-lg: 26px;
  --ease: cubic-bezier(.22,.8,.24,1);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  color: var(--text);
  background:
    radial-gradient(circle at 50% -220px, rgba(120,87,255,.13), transparent 430px),
    var(--bg);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text",
    "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body.dark {
  --bg: #050505;
  --surface: #111113;
  --surface-soft: rgba(20,20,22,.72);
  --text: #f5f5f7;
  --muted: #a1a1a6;
  --muted-2: #86868b;
  --line: rgba(255,255,255,.11);
  --shadow: 0 30px 100px rgba(0,0,0,.42);
  background:
    radial-gradient(circle at 50% -220px, rgba(100,77,255,.2), transparent 440px),
    var(--bg);
}

a { color: inherit; text-decoration: none; }
button { font: inherit; }
.container { width: min(1120px, calc(100% - 40px)); margin: 0 auto; }

.progress {
  position: fixed;
  inset: 0 auto auto 0;
  width: 0;
  height: 2px;
  z-index: 999;
  background: linear-gradient(90deg, #6f5cff, #0a84ff);
}

/* header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: color-mix(in srgb, var(--bg) 78%, transparent);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(24px) saturate(180%);
  -webkit-backdrop-filter: blur(24px) saturate(180%);
}

.nav {
  height: 60px;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
}

.brand {
  justify-self: start;
  display: inline-flex;
  align-items: center;
  gap: 9px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: -.01em;
}

.brand-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: linear-gradient(145deg, #8a67ff, #0a84ff);
  box-shadow: 0 0 20px rgba(88,94,255,.35);
}

.nav-links {
  display: flex;
  gap: 30px;
  color: var(--muted);
  font-size: 13px;
}

.nav-links a { transition: color .2s ease; }
.nav-links a:hover { color: var(--text); }

.theme-toggle {
  justify-self: end;
  position: relative;
  width: 38px;
  height: 28px;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--text);
  background: var(--surface-soft);
  cursor: pointer;
}

.theme-toggle span {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-size: 13px;
  transition: transform .35s var(--ease), opacity .25s ease;
}

.theme-toggle .moon { transform: translateY(30px); opacity: 0; }
body.dark .theme-toggle .sun { transform: translateY(-30px); opacity: 0; }
body.dark .theme-toggle .moon { transform: translateY(0); opacity: 1; }

/* hero */
.hero {
  padding: 128px 0 104px;
  text-align: center;
}

.hero-badge {
  width: fit-content;
  margin: 0 auto 28px;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 9px 13px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  background: var(--surface-soft);
  box-shadow: 0 10px 30px rgba(0,0,0,.025);
  font-size: 12px;
}

.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #34c759;
  box-shadow: 0 0 0 4px rgba(52,199,89,.12);
}

.hero h1 {
  max-width: 1020px;
  margin: 0 auto;
  font-size: clamp(54px, 7.8vw, 92px);
  line-height: .98;
  letter-spacing: -.068em;
}

.gradient-text {
  color: transparent;
  background: linear-gradient(95deg, #1d1d1f 2%, #755cff 44%, #0a84ff 88%);
  -webkit-background-clip: text;
  background-clip: text;
}

body.dark .gradient-text {
  background: linear-gradient(95deg, #fff 3%, #ae9aff 45%, #5eb1ff 90%);
  -webkit-background-clip: text;
  background-clip: text;
}

.hero-copy {
  max-width: 690px;
  margin: 34px auto 0;
  color: var(--muted);
  font-size: 18px;
  line-height: 1.8;
  letter-spacing: -.01em;
}

.hero-actions {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-top: 38px;
}

.button {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 13px 22px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 600;
  transition: transform .22s ease, background .22s ease, box-shadow .22s ease;
}

.button:hover { transform: translateY(-2px); }

.button.primary {
  color: #fff;
  background: var(--blue);
  box-shadow: 0 12px 30px rgba(0,113,227,.16);
}

.button.secondary {
  border: 1px solid var(--line);
  background: var(--surface-soft);
}

.hero-note {
  max-width: 540px;
  margin: 82px auto 0;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 14px;
  color: var(--muted-2);
  font-size: 11px;
  letter-spacing: .05em;
  text-transform: uppercase;
}

.hero-note .line { height: 1px; background: var(--line); }

/* spotlight */
.spotlight { padding-bottom: 118px; }

.spotlight-card {
  min-height: 540px;
  display: grid;
  grid-template-columns: 1fr .92fr;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-xl);
  background: var(--surface);
  box-shadow: var(--shadow);
  transition: transform .4s var(--ease), box-shadow .4s ease;
}

.spotlight-card:hover {
  transform: translateY(-7px);
  box-shadow: 0 38px 110px rgba(0,0,0,.12);
}

.spotlight-copy {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 54px 58px 48px;
}

.card-topline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: var(--muted-2);
  font-size: 10px;
  letter-spacing: .12em;
}

.pill {
  padding: 7px 9px;
  border-radius: 999px;
  color: var(--text);
  background: var(--bg);
  font-weight: 700;
}

.kicker {
  margin: 36px 0 12px;
  color: var(--blue);
  font-size: 14px;
  font-weight: 600;
}

.spotlight-copy h2 {
  max-width: 630px;
  margin: 0;
  font-size: clamp(40px, 5vw, 62px);
  line-height: 1.04;
  letter-spacing: -.052em;
}

.summary {
  max-width: 560px;
  margin: 24px 0 0;
  color: var(--muted);
  font-size: 16px;
  line-height: 1.75;
}

.read-link { font-size: 14px; font-weight: 650; }

.spotlight-visual {
  position: relative;
  min-height: 460px;
  overflow: hidden;
  background: linear-gradient(145deg, #111216, #252833);
}

.visual-noise {
  position: absolute;
  inset: 0;
  opacity: .1;
  background-image:
    linear-gradient(rgba(255,255,255,.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.04) 1px, transparent 1px);
  background-size: 34px 34px;
}

.glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(8px);
}

.glow-a {
  width: 300px;
  height: 300px;
  top: -50px;
  left: -40px;
  background: rgba(127,91,255,.36);
}

.glow-b {
  width: 320px;
  height: 320px;
  right: -80px;
  bottom: -70px;
  background: rgba(0,122,255,.32);
}

.browser-shell {
  position: absolute;
  width: 78%;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%) rotate(-2deg);
  overflow: hidden;
  border: 1px solid rgba(255,255,255,.24);
  border-radius: 24px;
  background: rgba(255,255,255,.13);
  box-shadow: 0 34px 70px rgba(0,0,0,.34);
  backdrop-filter: blur(26px);
}

.browser-bar {
  height: 48px;
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 0 14px;
  border-bottom: 1px solid rgba(255,255,255,.14);
}

.browser-bar > span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: rgba(255,255,255,.42);
}

.address {
  margin-left: 8px;
  flex: 1;
  padding: 7px 12px;
  border-radius: 8px;
  color: rgba(255,255,255,.58);
  background: rgba(255,255,255,.09);
  font-size: 9px;
}

.browser-body { padding: 46px 34px 54px; }

.tiny-label {
  color: rgba(255,255,255,.48);
  font-size: 8px;
  letter-spacing: .18em;
}

.visual-title,
.visual-copy {
  border-radius: 999px;
  background: rgba(255,255,255,.83);
}

.visual-title {
  height: 14px;
  width: 82%;
  margin-top: 24px;
}

.visual-title.short { width: 58%; margin-top: 10px; }
.visual-copy { width: 76%; height: 6px; margin-top: 26px; opacity: .35; }
.visual-copy.shorter { width: 52%; margin-top: 8px; }

/* writing */
.section { padding: 20px 0 130px; }

.section-heading {
  display: flex;
  justify-content: space-between;
  align-items: end;
  margin-bottom: 36px;
}

.eyebrow {
  margin-bottom: 12px;
  color: var(--muted-2);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .18em;
}

.section-heading h2,
.about-title h2 {
  margin: 0;
  font-size: clamp(40px, 5vw, 58px);
  line-height: 1;
  letter-spacing: -.052em;
}

.all-link {
  padding-bottom: 5px;
  color: var(--muted);
  font-size: 13px;
}

.post-grid {
  display: grid;
  grid-template-columns: 1.18fr .82fr;
  gap: 18px;
}

.post-card {
  min-height: 330px;
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  background: var(--surface);
  transition: transform .28s var(--ease), box-shadow .28s ease;
}

.post-card.large {
  grid-row: span 2;
  min-height: 678px;
}

.post-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 24px 70px rgba(0,0,0,.08);
}

.post-card a {
  height: 100%;
  min-height: inherit;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 30px;
}

.post-card.large a { padding: 38px; }

.post-card-top,
.post-card-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--muted-2);
  font-size: 11px;
}

.category {
  padding: 7px 10px;
  border-radius: 999px;
  color: var(--text);
  background: var(--bg);
  font-weight: 650;
}

.post-card-body h3 {
  max-width: 760px;
  margin: 0 0 15px;
  font-size: 27px;
  line-height: 1.16;
  letter-spacing: -.035em;
}

.post-card.large h3 {
  font-size: clamp(38px, 4.6vw, 58px);
  line-height: 1.04;
  letter-spacing: -.052em;
}

.post-card-body p {
  max-width: 660px;
  margin: 0;
  color: var(--muted);
  font-size: 14px;
  line-height: 1.7;
}

.post-card.large p { font-size: 16px; }

.circle-arrow {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  transition: transform .2s ease, background .2s ease;
}

.post-card:hover .circle-arrow {
  transform: translate(2px, -2px);
  background: var(--bg);
}

/* quote */
.quote-section { padding-bottom: 130px; }

.quote-card {
  padding: 86px 50px;
  text-align: center;
  border-radius: var(--radius-xl);
  background: linear-gradient(145deg, #111216, #252833);
  color: white;
}

.quote-mark {
  display: block;
  height: 44px;
  color: rgba(255,255,255,.25);
  font-family: Georgia, serif;
  font-size: 74px;
  line-height: 1;
}

.quote-card p {
  max-width: 760px;
  margin: 14px auto 20px;
  font-size: clamp(34px, 5vw, 58px);
  line-height: 1.1;
  letter-spacing: -.048em;
}

.quote-sub {
  color: rgba(255,255,255,.48);
  font-size: 12px;
  letter-spacing: .08em;
}

/* about */
.about-section {
  padding: 120px 0;
  color: #f5f5f7;
  background: #000;
}

.about-grid {
  display: grid;
  grid-template-columns: .85fr 1.15fr;
  gap: 100px;
}

.about-title .eyebrow { color: #68686d; }

.about-copy .lead {
  margin: 0 0 28px;
  font-size: 28px;
  line-height: 1.45;
  letter-spacing: -.03em;
}

.about-copy > p:not(.lead) {
  max-width: 680px;
  margin: 0;
  color: #9b9ba0;
  font-size: 16px;
  line-height: 1.9;
}

.about-meta {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
  margin-top: 48px;
}

.about-meta > div {
  padding-top: 18px;
  border-top: 1px solid rgba(255,255,255,.13);
}

.meta-label {
  display: block;
  margin-bottom: 8px;
  color: #66666b;
  font-size: 9px;
  letter-spacing: .16em;
}

.about-meta strong { font-size: 14px; }

.about-links {
  display: flex;
  gap: 28px;
  margin-top: 46px;
  color: #d7d7db;
  font-size: 13px;
}

.about-links a:hover { color: white; }

/* footer */
.footer {
  min-height: 150px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--muted);
  font-size: 12px;
}

.footer strong { color: var(--text); font-size: 13px; }
.footer p { margin: 7px 0 0; }

.footer-right {
  display: flex;
  align-items: center;
  gap: 24px;
}

/* reveal */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity .75s var(--ease), transform .75s var(--ease);
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 860px) {
  .hero { padding-top: 105px; }
  .spotlight-card,
  .about-grid { grid-template-columns: 1fr; }
  .spotlight-visual { min-height: 410px; }
  .post-grid { grid-template-columns: 1fr; }
  .post-card.large { grid-row: auto; min-height: 440px; }
  .about-grid { gap: 54px; }
}

@media (max-width: 560px) {
  .container { width: min(100% - 28px, 1120px); }

  .nav {
    height: 56px;
    grid-template-columns: 1fr auto;
  }

  .nav-links { display: none; }

  .hero {
    padding: 86px 0 76px;
    text-align: left;
  }

  .hero-badge {
    margin-left: 0;
    line-height: 1.3;
  }

  .hero h1 {
    font-size: clamp(47px, 14vw, 67px);
  }

  .hero-copy {
    margin-left: 0;
    font-size: 16px;
  }

  .hero-actions { justify-content: flex-start; }

  .hero-note {
    margin-top: 60px;
    grid-template-columns: auto 1fr;
  }

  .hero-note span:last-child { display: none; }

  .spotlight-card { border-radius: 25px; }
  .spotlight-copy { padding: 34px 24px; min-height: 460px; }
  .spotlight-copy h2 { font-size: 39px; }
  .spotlight-visual { min-height: 310px; }
  .browser-shell { width: 86%; }

  .section-heading { align-items: start; gap: 18px; }
  .section-heading h2 { font-size: 38px; }
  .all-link { white-space: nowrap; }

  .post-card,
  .post-card.large { min-height: 360px; border-radius: 22px; }

  .post-card a,
  .post-card.large a { padding: 25px; }

  .post-card.large h3 { font-size: 37px; }
  .post-card-body h3 { font-size: 25px; }

  .quote-card { padding: 70px 24px; border-radius: 25px; }

  .about-section { padding: 88px 0; }
  .about-copy .lead { font-size: 24px; }
  .about-meta { grid-template-columns: 1fr; }

  .footer {
    min-height: 170px;
    align-items: flex-start;
    flex-direction: column;
    justify-content: center;
    gap: 24px;
  }

  .footer-right {
    width: 100%;
    justify-content: space-between;
  }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
  .reveal { opacity: 1; transform: none; }
}
