:root {
  --bg: #05060a;
  --ink: #eef3ff;
  --dim: #8b95b2;
  --cyan: #5ce1ff;
  --magenta: #ff4d9a;
  --gold: #f4c56e;
  --line: rgba(238, 243, 255, 0.12);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
html, body { background: var(--bg); color: var(--ink); }
body {
  font-family: "Syne", "Noto Sans SC", sans-serif;
  overflow-x: hidden;
  cursor: none;
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; }

#gl {
  position: fixed;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
}
.grain, .vignette {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 2;
}
.grain {
  opacity: 0.12;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  mix-blend-mode: overlay;
  animation: grain 1.2s steps(4) infinite;
}
@keyframes grain {
  0%, 100% { transform: translate(0,0); }
  25% { transform: translate(-1%, 1%); }
  50% { transform: translate(1%, -1%); }
  75% { transform: translate(-1%, -2%); }
}
.vignette {
  background:
    radial-gradient(ellipse at center, transparent 40%, rgba(0,0,0,.55) 100%),
    linear-gradient(180deg, rgba(0,0,0,.35), transparent 18%, transparent 80%, rgba(0,0,0,.5));
}

.cursor {
  position: fixed;
  top: 0; left: 0;
  width: 14px; height: 14px;
  border-radius: 50%;
  border: 1px solid var(--cyan);
  z-index: 50;
  pointer-events: none;
  mix-blend-mode: difference;
  transform: translate(-50%, -50%);
  transition: width .25s, height .25s, background .25s, border-color .25s;
}
.cursor span {
  position: absolute;
  inset: 4px;
  border-radius: 50%;
  background: var(--cyan);
}
.cursor.grow {
  width: 64px; height: 64px;
  background: rgba(92,225,255,.12);
}
.cursor.grow span { opacity: 0; }
.cursor-label {
  position: fixed;
  z-index: 51;
  pointer-events: none;
  font-family: "JetBrains Mono", monospace;
  font-size: 10px;
  letter-spacing: .28em;
  color: var(--bg);
  background: var(--cyan);
  padding: 4px 8px;
  border-radius: 999px;
  opacity: 0;
  transform: translate(18px, 18px);
  transition: opacity .2s;
}

#boot {
  position: fixed;
  inset: 0;
  z-index: 80;
  background: #03040a;
  display: grid;
  place-items: center;
  transition: opacity .7s ease, visibility .7s;
}
#boot.done { opacity: 0; visibility: hidden; pointer-events: none; }
.boot-inner { width: min(520px, 86vw); }
.boot-kicker, .boot-log {
  font-family: "JetBrains Mono", monospace;
  font-size: 11px;
  letter-spacing: .28em;
  color: var(--cyan);
}
.boot-title {
  font-size: clamp(32px, 6vw, 56px);
  font-weight: 800;
  letter-spacing: .08em;
  margin: 12px 0 22px;
}
.boot-bar {
  height: 2px;
  background: rgba(238,243,255,.12);
  overflow: hidden;
}
.boot-bar span {
  display: block;
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, var(--magenta), var(--cyan), var(--gold));
}
.boot-log { margin-top: 16px; min-height: 3em; color: var(--dim); }

.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 32px;
  mix-blend-mode: difference;
}
.logo { display: flex; align-items: center; gap: 10px; font-weight: 700; letter-spacing: .24em; font-size: 13px; }
.logo-mark {
  width: 32px; height: 32px;
  display: grid; place-items: center;
  border: 1px solid currentColor;
  border-radius: 50%;
  font-size: 11px;
}
.nav ul { display: flex; gap: 28px; list-style: none; font-size: 13px; letter-spacing: .18em; }
.nav-meta {
  display: flex; align-items: center; gap: 10px;
  font-family: "JetBrains Mono", monospace;
  font-size: 11px;
  letter-spacing: .16em;
}
.dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: #3dff9a;
  box-shadow: 0 0 12px #3dff9a;
  animation: pulse 1.6s ease-in-out infinite;
}
@keyframes pulse {
  0%,100% { opacity: 1; }
  50% { opacity: .35; }
}

main { position: relative; z-index: 3; }

.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 120px 8vw 80px;
}
.hero-meta { display: flex; gap: 10px; margin-bottom: 28px; }
.chip {
  font-family: "JetBrains Mono", monospace;
  font-size: 11px;
  letter-spacing: .2em;
  border: 1px solid var(--line);
  padding: 6px 10px;
  border-radius: 999px;
}
.chip.live { display: flex; align-items: center; gap: 8px; }
.chip.live i {
  width: 6px; height: 6px; border-radius: 50%; background: #3dff9a;
}
.hero-title { line-height: .92; }
.hero-title .line {
  display: block;
  font-size: clamp(56px, 12vw, 168px);
  font-weight: 800;
  letter-spacing: -.04em;
}
.hero-title em { font-family: "Instrument Serif", serif; font-style: italic; font-weight: 400; }
.hero-title .outline {
  color: transparent;
  -webkit-text-stroke: 1.4px var(--ink);
  text-shadow: 0 0 40px rgba(92,225,255,.25);
}
.hero-title .small {
  margin-top: 18px;
  font-size: clamp(12px, 1.4vw, 16px);
  letter-spacing: .42em;
  font-weight: 500;
  color: var(--cyan);
}
.hero-lead {
  max-width: 520px;
  margin: 28px 0 36px;
  color: var(--dim);
  font-size: 18px;
  line-height: 1.7;
}
.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; }
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 22px;
  border-radius: 999px;
  background: var(--ink);
  color: var(--bg);
  font-weight: 700;
  letter-spacing: .12em;
  font-size: 13px;
  transition: transform .25s, box-shadow .25s;
  box-shadow: 0 0 0 0 rgba(92,225,255,.4);
}
.btn:hover { transform: translateY(-2px); box-shadow: 0 0 28px rgba(92,225,255,.35); }
.btn.ghost {
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--line);
}
.hero-scroll {
  position: absolute;
  right: 8vw;
  bottom: 80px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  font-family: "JetBrains Mono", monospace;
  font-size: 10px;
  letter-spacing: .3em;
}
.hero-scroll b {
  width: 1px; height: 72px;
  background: linear-gradient(180deg, var(--cyan), transparent);
  animation: drop 1.8s ease-in-out infinite;
}
@keyframes drop {
  0% { transform: scaleY(0); transform-origin: top; opacity: 0; }
  40% { transform: scaleY(1); opacity: 1; }
  100% { transform: scaleY(1) translateY(12px); opacity: 0; }
}

.marquee {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  overflow: hidden;
  padding: 18px 0;
}
.marquee-track {
  display: flex;
  gap: 64px;
  width: max-content;
  animation: slide 22s linear infinite;
  font-size: 13px;
  letter-spacing: .5em;
  color: var(--dim);
}
@keyframes slide {
  to { transform: translateX(-50%); }
}

.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1px;
  background: var(--line);
  border-bottom: 1px solid var(--line);
}
.stats article {
  background: rgba(5,6,10,.55);
  padding: 42px 8vw 42px 32px;
}
.stats b {
  display: block;
  font-size: clamp(36px, 5vw, 64px);
  font-weight: 800;
  background: linear-gradient(90deg, var(--ink), var(--cyan));
  -webkit-background-clip: text;
  color: transparent;
}
.stats span { color: var(--dim); font-size: 13px; letter-spacing: .16em; }

section { padding: 100px 8vw; }
.sec-head { margin-bottom: 48px; }
.sec-head .idx {
  font-family: "JetBrains Mono", monospace;
  color: var(--magenta);
  letter-spacing: .3em;
  font-size: 12px;
}
.sec-head h2 {
  font-size: clamp(36px, 6vw, 72px);
  letter-spacing: -.03em;
  margin: 8px 0 12px;
}
.sec-head p { color: var(--dim); max-width: 420px; }

.work-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 18px;
}
.card {
  border: 1px solid var(--line);
  background: rgba(255,255,255,.03);
  overflow: hidden;
  transform-style: preserve-3d;
  transition: border-color .3s;
}
.card:hover { border-color: rgba(92,225,255,.45); }
.card-media {
  min-height: 280px;
  padding: 28px;
  position: relative;
  background:
    radial-gradient(600px 240px at 20% 20%, rgba(255,77,154,.35), transparent 50%),
    radial-gradient(500px 260px at 80% 80%, rgba(92,225,255,.28), transparent 50%),
    linear-gradient(160deg, #14182a, #07080f);
  overflow: hidden;
}
.card-media.alt.a { background: linear-gradient(135deg, #1a1030, #0b1d2a 50%, #2a1230); min-height: 180px; }
.card-media.alt.b { background: linear-gradient(135deg, #102018, #0c1428 55%, #24180c); min-height: 180px; }
.card-media.alt.c { background: linear-gradient(135deg, #180c28, #0c2030); min-height: 180px; }
.card-glow {
  position: absolute;
  width: 240px; height: 240px;
  right: -40px; top: -40px;
  background: radial-gradient(circle, rgba(244,197,110,.55), transparent 65%);
  filter: blur(8px);
  animation: float 6s ease-in-out infinite;
}
@keyframes float {
  50% { transform: translate(-20px, 24px) scale(1.1); }
}
.card-num {
  font-family: "JetBrains Mono", monospace;
  opacity: .45;
  letter-spacing: .2em;
}
.card-media h3 {
  position: absolute;
  left: 28px; bottom: 24px;
  font-size: clamp(28px, 4vw, 52px);
  line-height: 1.05;
}
.card-body { padding: 22px 24px 26px; }
.card-body span {
  font-family: "JetBrains Mono", monospace;
  font-size: 11px;
  letter-spacing: .22em;
  color: var(--gold);
}
.card-body p { margin-top: 8px; color: var(--dim); line-height: 1.65; }

.featured { grid-row: span 2; }
.featured .card-media { min-height: 420px; }

.posts { display: grid; gap: 0; }
.post {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 24px;
  padding: 28px 0;
  border-top: 1px solid var(--line);
  transition: background .3s, padding-left .3s;
}
.post:hover { padding-left: 12px; background: linear-gradient(90deg, rgba(92,225,255,.06), transparent); }
.post time {
  font-family: "JetBrains Mono", monospace;
  color: var(--cyan);
  font-size: 12px;
  padding-top: 8px;
}
.post h3 { font-size: 28px; margin-bottom: 8px; }
.post p { color: var(--dim); max-width: 640px; line-height: 1.7; }

.about-grid {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 64px;
  align-items: center;
}
.portrait {
  width: 260px; height: 320px;
  margin: 0 auto;
  position: relative;
  display: grid;
  place-items: center;
}
.portrait-ring {
  position: absolute;
  inset: 0;
  border: 1px solid rgba(92,225,255,.4);
  border-radius: 40% 60% 55% 45% / 45% 40% 60% 55%;
  animation: morph 8s ease-in-out infinite;
}
.portrait-core {
  width: 180px; height: 180px;
  border-radius: 50%;
  display: grid; place-items: center;
  font-family: "Instrument Serif", serif;
  font-size: 72px;
  background: radial-gradient(circle at 30% 30%, #fff, #5ce1ff 40%, #ff4d9a 90%);
  color: #05060a;
  box-shadow: 0 0 80px rgba(92,225,255,.35);
}
@keyframes morph {
  0%,100% { border-radius: 40% 60% 55% 45% / 45% 40% 60% 55%; transform: rotate(0); }
  50% { border-radius: 60% 40% 35% 65% / 55% 60% 40% 45%; transform: rotate(12deg); }
}
.about-copy .big {
  font-family: "Instrument Serif", serif;
  font-size: clamp(28px, 4vw, 44px);
  margin-bottom: 16px;
}
.about-copy p { color: var(--dim); line-height: 1.8; margin-bottom: 14px; max-width: 560px; }
.tags { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; margin-top: 18px; }
.tags li {
  border: 1px solid var(--line);
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 12px;
  letter-spacing: .16em;
}

.contact { text-align: left; }
.mail {
  display: inline-block;
  font-size: clamp(28px, 6vw, 72px);
  font-weight: 800;
  letter-spacing: -.03em;
  background: linear-gradient(90deg, var(--ink), var(--cyan), var(--magenta));
  background-size: 200% 100%;
  -webkit-background-clip: text;
  color: transparent;
  animation: hue 8s linear infinite;
}
.mail span { color: var(--gold); -webkit-text-fill-color: var(--gold); }
@keyframes hue { to { background-position: 200% 0; } }
.fine { color: var(--dim); margin: 18px 0 28px; }

.foot {
  position: relative;
  z-index: 3;
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 28px 8vw 40px;
  border-top: 1px solid var(--line);
  font-family: "JetBrains Mono", monospace;
  font-size: 11px;
  letter-spacing: .16em;
  color: var(--dim);
}

@media (max-width: 900px) {
  body { cursor: auto; }
  .cursor, .cursor-label { display: none; }
  .nav { padding: 16px 18px; }
  .nav ul { display: none; }
  .hero { padding: 110px 22px 70px; }
  .hero-scroll { display: none; }
  .stats { grid-template-columns: 1fr 1fr; }
  .stats article { padding: 28px 22px; }
  section { padding: 72px 22px; }
  .work-grid, .about-grid, .post { grid-template-columns: 1fr; }
  .featured { grid-row: auto; }
  .foot { flex-direction: column; padding: 24px 22px 36px; }
}
