@import url("https://fonts.googleapis.com/css2?family=Space+Mono:ital,wght@0,400;0,700;1,400&family=Syne:wght@400;700;800&display=swap");

* {
  box-sizing: border-box;
}

:root {
  --bg: #0a0a0c;
  --bg-2: #111116;
  --bg-3: #17171f;
  --fg: #f0ede6;
  --muted: #8a8880;
  --line: rgba(240, 237, 230, 0.11);
  --soft-line: rgba(240, 237, 230, 0.06);
  --accent: #e4f84e;
  --danger: #ff6b5f;
  --cyan: #6fd6ff;
  --mono: "Space Mono", monospace;
  --sans: "Syne", sans-serif;
  --cjk-sans: "PingFang SC", "Hiragino Sans", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans CJK SC", "Noto Sans CJK JP", sans-serif;
  --max: 1400px;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--sans);
  overflow-x: hidden;
}

:is(html[lang="zh-CN"], html[lang="zh-Hant"], html[lang="ja"]) {
  --mono: var(--cjk-sans);
  --sans: var(--cjk-sans);
}

:is(html[lang="zh-CN"], html[lang="zh-Hant"], html[lang="ja"]) .brand {
  font-family: "Space Mono", monospace;
}

:is(html[lang="zh-CN"], html[lang="zh-Hant"], html[lang="ja"]) .hero h1,
:is(html[lang="zh-CN"], html[lang="zh-Hant"], html[lang="ja"]) .work-card h2,
:is(html[lang="zh-CN"], html[lang="zh-Hant"], html[lang="ja"]) .work-card h3,
:is(html[lang="zh-CN"], html[lang="zh-Hant"], html[lang="ja"]) .blog-intro h2,
:is(html[lang="zh-CN"], html[lang="zh-Hant"], html[lang="ja"]) .about-copy h2,
:is(html[lang="zh-CN"], html[lang="zh-Hant"], html[lang="ja"]) .page-hero h1,
:is(html[lang="zh-CN"], html[lang="zh-Hant"], html[lang="ja"]) .listing h1 {
  letter-spacing: -0.02em;
  line-height: 1.05;
}

:is(html[lang="zh-CN"], html[lang="zh-Hant"], html[lang="ja"]) .hero {
  align-items: end;
  padding-top: clamp(7rem, 14vh, 10rem);
  padding-bottom: clamp(3rem, 8vh, 5rem);
}

:is(html[lang="zh-CN"], html[lang="zh-Hant"], html[lang="ja"]) .hero h1 {
  max-width: 1220px;
  font-size: clamp(5.4rem, 11vw, 11.2rem);
  line-height: 0.95;
}

:is(html[lang="zh-CN"], html[lang="zh-Hant"], html[lang="ja"]) .hero-copy {
  max-width: 660px;
  margin-top: clamp(2.25rem, 3vw, 3rem);
  line-height: 1.95;
}

:is(html[lang="zh-CN"], html[lang="zh-Hant"], html[lang="ja"]) .hero-actions {
  margin-top: clamp(2.75rem, 4vw, 3.5rem);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 80;
  pointer-events: none;
  opacity: 0.38;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.032'/%3E%3C/svg%3E");
}

a {
  color: inherit;
}

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

.site-shell {
  min-height: 100dvh;
  position: relative;
}

.topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 60;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  padding: 1.35rem clamp(1.25rem, 4vw, 3rem);
}

.topbar::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(to bottom, rgba(10, 10, 12, 0.96), rgba(10, 10, 12, 0));
}

.brand {
  font-family: var(--mono);
  font-size: 0.85rem;
  letter-spacing: 0.16em;
  text-decoration: none;
  color: var(--muted);
  text-transform: uppercase;
}

.brand span {
  color: var(--accent);
}

.brand:hover span {
  animation: glitch 0.34s steps(2) forwards;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: clamp(1rem, 3vw, 2.5rem);
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.nav-links a {
  color: var(--muted);
  text-decoration: none;
  transition: color 180ms ease;
}

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

.lang-menu {
  position: relative;
  z-index: 70;
}

.lang-button {
  appearance: none;
  display: inline-grid;
  grid-template-columns: 1fr 0.55rem;
  align-items: center;
  gap: 0.45rem;
  min-width: 4.45rem;
  min-height: 30px;
  border: 1px solid rgba(240, 237, 230, 0.18);
  background: rgba(10, 10, 12, 0.36);
  color: var(--fg);
  padding: 0.35rem 0.58rem 0.35rem 0.62rem;
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.1em;
  text-align: left;
  text-transform: uppercase;
  cursor: pointer;
  clip-path: polygon(0 0, calc(100% - 7px) 0, 100% 7px, 100% 100%, 7px 100%, 0 calc(100% - 7px));
  transition: color 180ms ease, border-color 180ms ease, background 180ms ease, transform 180ms ease;
}

.lang-caret {
  width: 7px;
  height: 7px;
  background:
    linear-gradient(45deg, transparent 50%, currentColor 50%) 0 50% / 5px 5px no-repeat,
    linear-gradient(135deg, currentColor 50%, transparent 50%) 4px 50% / 5px 5px no-repeat;
  transition: transform 180ms ease;
}

.lang-list {
  position: absolute;
  top: calc(100% + 0.48rem);
  right: 0;
  width: min(13rem, calc(100vw - 2rem));
  padding: 0.38rem;
  border: 1px solid rgba(228, 248, 78, 0.28);
  background:
    linear-gradient(135deg, rgba(228, 248, 78, 0.08), transparent 28%),
    rgba(10, 10, 12, 0.96);
  box-shadow: 0 20px 42px rgba(0, 0, 0, 0.42);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transform: translate3d(0, -0.45rem, 0);
  clip-path: polygon(0 0, calc(100% - 11px) 0, 100% 11px, 100% 100%, 11px 100%, 0 calc(100% - 11px));
  transition: opacity 160ms ease, transform 160ms ease;
}

.lang-list::before {
  content: "";
  position: absolute;
  top: -4px;
  right: 1.1rem;
  width: 7px;
  height: 7px;
  background: var(--accent);
  box-shadow: 7px 7px 0 rgba(228, 248, 78, 0.45);
}

.lang-list button {
  appearance: none;
  position: relative;
  display: grid;
  grid-template-columns: 2.2rem 1fr;
  align-items: center;
  gap: 0.65rem;
  width: 100%;
  border: 0;
  background: transparent;
  color: var(--muted);
  padding: 0.58rem 0.64rem;
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  text-align: left;
  cursor: pointer;
  transition: color 160ms ease, background 160ms ease, transform 160ms ease;
}

.lang-list button + button {
  border-top: 1px solid var(--soft-line);
}

.lang-list button span {
  color: var(--fg);
  font-weight: 700;
}

.lang-list button small {
  color: inherit;
  font-size: 0.62rem;
  letter-spacing: 0.03em;
}

.lang-list button:hover,
.lang-list button:focus-visible,
.lang-list button.is-active {
  background: rgba(228, 248, 78, 0.08);
  color: var(--fg);
  outline: 0;
}

.lang-list button.is-active::before {
  content: "";
  position: absolute;
  left: 0.2rem;
  top: 50%;
  width: 5px;
  height: 5px;
  background: var(--accent);
  box-shadow: 5px 5px 0 rgba(228, 248, 78, 0.6);
  transform: translateY(-50%);
}

.lang-menu.is-open .lang-button,
.lang-button:hover,
.lang-button:focus-visible {
  color: var(--accent);
  border-color: rgba(228, 248, 78, 0.5);
  background: rgba(228, 248, 78, 0.06);
  transform: translate3d(-1px, -1px, 0);
  outline: 0;
}

.lang-menu.is-open .lang-caret {
  transform: rotate(180deg);
}

.lang-menu.is-open .lang-list {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translate3d(0, 0, 0);
}

.lang-button:active {
  transform: translate3d(0, 0, 0) scale(0.98);
}

.pixel-cursor {
  position: fixed;
  left: 0;
  top: 0;
  z-index: 90;
  width: 14px;
  height: 14px;
  pointer-events: none;
  opacity: 0;
  transform: translate3d(-30px, -30px, 0);
  background:
    linear-gradient(var(--accent), var(--accent)) 0 0 / 7px 7px no-repeat,
    linear-gradient(var(--accent), var(--accent)) 7px 7px / 7px 7px no-repeat;
  mix-blend-mode: difference;
  transition: opacity 160ms ease, width 160ms ease, height 160ms ease;
}

.pixel-cursor.is-active {
  width: 28px;
  height: 28px;
}

.hero {
  min-height: 100dvh;
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: end;
  max-width: var(--max);
  margin: 0 auto;
  padding: clamp(7rem, 14vh, 10rem) clamp(1.25rem, 4vw, 3rem) clamp(3rem, 8vh, 5rem);
  overflow: hidden;
}

.hero::after {
  content: "PIXEL";
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: -1;
  transform: translate(-50%, -52%);
  font-size: clamp(9rem, 25vw, 25rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: transparent;
  -webkit-text-stroke: 1px rgba(240, 237, 230, 0.045);
  white-space: nowrap;
}

.hero-grid {
  position: absolute;
  top: 0;
  right: 0;
  z-index: -2;
  width: 54%;
  height: 100%;
  opacity: 0.09;
  background-image:
    linear-gradient(rgba(228, 248, 78, 0.48) 1px, transparent 1px),
    linear-gradient(90deg, rgba(228, 248, 78, 0.48) 1px, transparent 1px);
  background-size: 40px 40px;
  mask-image: linear-gradient(to left, rgba(0, 0, 0, 0.86), transparent);
}

.eyebrow,
.section-label,
.tiny-label {
  font-family: var(--mono);
  color: var(--accent);
  letter-spacing: 0.22em;
  text-transform: uppercase;
}

.eyebrow {
  font-size: 0.73rem;
  margin-bottom: 1.4rem;
}

.hero h1 {
  margin: 0;
  max-width: 1080px;
  font-size: clamp(3.55rem, 8vw, 7.6rem);
  line-height: 0.92;
  letter-spacing: -0.035em;
  font-weight: 800;
  overflow-wrap: anywhere;
}

.hero h1 .accent {
  color: var(--accent);
  display: block;
}

.hero-copy {
  margin: 2rem 0 0;
  max-width: 570px;
  font-family: var(--mono);
  color: var(--muted);
  font-size: 0.86rem;
  line-height: 1.8;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
  margin-top: 2.6rem;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0.85rem 1.4rem;
  font-family: var(--mono);
  font-size: 0.74rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  border: 1px solid var(--line);
  color: var(--fg);
  transition: transform 180ms ease, background 180ms ease, color 180ms ease, border-color 180ms ease;
  clip-path: polygon(0 0, calc(100% - 10px) 0, 100% 10px, 100% 100%, 10px 100%, 0 calc(100% - 10px));
}

.button.primary {
  background: var(--accent);
  color: var(--bg);
  border-color: var(--accent);
}

.button:hover {
  transform: translate3d(-2px, -2px, 0);
  border-color: rgba(228, 248, 78, 0.52);
}

.button:active {
  transform: translate3d(0, 0, 0) scale(0.98);
}

.app-icon {
  width: 104px;
  height: 104px;
  position: relative;
  margin-bottom: 1.2rem;
  image-rendering: pixelated;
}

.app-icon img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 24px;
  border: 1px solid rgba(240, 237, 230, 0.16);
  image-rendering: pixelated;
}

.app-icon .icon-clear {
  opacity: 0;
  image-rendering: auto;
  transition: opacity 180ms ease;
}

a:hover .app-icon .icon-clear,
.work-card:hover .app-icon .icon-clear {
  opacity: 1;
}

.concept-icon {
  display: grid;
  place-items: center;
  width: 104px;
  height: 104px;
  border: 1px solid rgba(240, 237, 230, 0.16);
  border-radius: 24px;
  background: #101014;
  overflow: hidden;
}

.concept-icon img {
  width: 100%;
  height: 100%;
  image-rendering: pixelated;
}

.status,
.tag {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-family: var(--mono);
  font-size: 0.64rem;
  line-height: 1;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}

.status::before {
  content: "";
  width: 7px;
  height: 7px;
  background: currentColor;
}

.status.live {
  color: var(--accent);
}

.status.dev {
  color: var(--danger);
}

.status.concept {
  color: var(--cyan);
}

.marquee-wrap {
  overflow: hidden;
  border-top: 1px solid var(--soft-line);
  border-bottom: 1px solid var(--soft-line);
  background: var(--bg-2);
}

.marquee {
  display: flex;
  width: max-content;
  gap: 2.5rem;
  padding: 1.05rem 0;
  animation: marquee 24s linear infinite;
  white-space: nowrap;
}

.marquee span {
  font-family: var(--mono);
  font-size: 0.68rem;
  color: var(--muted);
  letter-spacing: 0.2em;
  text-transform: uppercase;
}

.marquee .mark {
  color: var(--accent);
  font-weight: 700;
}

.section {
  max-width: var(--max);
  margin: 0 auto;
  padding: clamp(4.5rem, 9vw, 7.5rem) clamp(1.25rem, 4vw, 3rem);
}

.section-label {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 2.8rem;
  font-size: 0.7rem;
}

.section-label::before {
  content: "";
  width: 2rem;
  height: 1px;
  background: var(--accent);
}

.work-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1px;
  background: var(--soft-line);
  align-items: stretch;
}

.work-card {
  min-height: 540px;
  position: relative;
  display: grid;
  align-content: space-between;
  padding: clamp(1.35rem, 3vw, 2.6rem);
  background: var(--bg);
  overflow: hidden;
  text-decoration: none;
  transition: background 220ms ease, transform 220ms ease;
  isolation: isolate;
}

.work-card:hover {
  z-index: 2;
  background: var(--bg-2);
  transform: translate3d(-2px, -2px, 0);
}

.work-card::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  width: 3px;
  height: 0;
  background: var(--accent);
  transition: height 360ms cubic-bezier(0.16, 1, 0.3, 1);
}

.work-card:hover::before {
  height: 100%;
}

.work-card::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  opacity: 0.88;
  pointer-events: none;
}

.work-card h2,
.work-card h3 {
  margin: 1rem 0 0.8rem;
  font-size: clamp(2.1rem, 3.4vw, 3.6rem);
  line-height: 0.94;
  letter-spacing: -0.04em;
}

.work-card h3 {
  font-size: clamp(2.1rem, 3.4vw, 3.6rem);
}

.paperwave-card {
  color: var(--fg);
  background:
    linear-gradient(180deg, rgba(245, 245, 247, 0.075), rgba(245, 245, 247, 0.025)),
    var(--bg);
}

.paperwave-card::before {
  background: #ff8a3c;
}

.paperwave-card::after {
  background:
    linear-gradient(rgba(245, 245, 247, 0.055) 1px, transparent 1px) 0 0 / 100% 34px,
    radial-gradient(circle at 84% 16%, rgba(255, 138, 60, 0.24), transparent 31%),
    linear-gradient(145deg, rgba(245, 245, 247, 0.12), rgba(226, 232, 240, 0.04) 46%, transparent 78%);
}

.paperwave-card p,
.paperwave-card .tag {
  color: rgba(240, 237, 230, 0.72);
}

.paperwave-card .tag {
  border-color: rgba(245, 245, 247, 0.16);
}

.paperwave-card .status.live,
.paperwave-card .card-link {
  color: #ff8a3c;
}

.peekr-card {
  color: #f8f0df;
  background:
    linear-gradient(145deg, rgba(7, 95, 72, 0.44), rgba(4, 59, 48, 0.2) 58%, rgba(7, 95, 72, 0.08)),
    var(--bg);
}

.peekr-card::before {
  background: #e8bd4e;
}

.peekr-card::after {
  background:
    radial-gradient(circle at 50% 15%, rgba(248, 240, 223, 0.11), transparent 23%),
    radial-gradient(circle at 12% 86%, rgba(52, 208, 170, 0.16), transparent 28%),
    repeating-linear-gradient(45deg, rgba(248, 240, 223, 0.04) 0 1px, transparent 1px 9px),
    linear-gradient(145deg, rgba(7, 95, 72, 0.35), rgba(4, 59, 48, 0.14) 74%);
}

.peekr-card p,
.peekr-card .tag {
  color: rgba(248, 240, 223, 0.74);
}

.peekr-card .tag {
  border-color: rgba(248, 240, 223, 0.18);
}

.peekr-card .status.dev,
.peekr-card .card-link {
  color: #e8bd4e;
}

.melodot-card::after {
  background:
    radial-gradient(circle at 18% 20%, rgba(111, 214, 255, 0.12), transparent 28%),
    radial-gradient(circle at 86% 24%, rgba(255, 107, 95, 0.14), transparent 25%),
    linear-gradient(rgba(228, 248, 78, 0.075) 1px, transparent 1px),
    linear-gradient(90deg, rgba(228, 248, 78, 0.06) 1px, transparent 1px);
  background-size: auto, auto, 28px 28px, 28px 28px;
}

.work-card p,
.blog-card p,
.about-copy p,
.page-copy {
  font-family: var(--mono);
  color: var(--muted);
  font-size: 0.8rem;
  line-height: 1.78;
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin-top: 1.6rem;
}

.tag {
  padding: 0.42rem 0.72rem;
  border: 1px solid rgba(240, 237, 230, 0.12);
}

.paperwave-card p,
.paperwave-card .tag {
  color: rgba(240, 237, 230, 0.82);
}

.paperwave-card .tag {
  border-color: rgba(245, 245, 247, 0.22);
}

.peekr-card p,
.peekr-card .tag {
  color: rgba(248, 240, 223, 0.78);
}

.card-link {
  margin-top: 2rem;
  font-family: var(--mono);
  font-size: 0.7rem;
  color: var(--accent);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.blog-strip {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 1px;
  background: var(--soft-line);
}

.blog-intro,
.blog-list,
.about-copy,
.idea-panel {
  background: var(--bg);
  padding: clamp(1.35rem, 3vw, 2.6rem);
}

.blog-intro h2,
.about-copy h2,
.page-hero h1 {
  margin: 0;
  font-size: clamp(2.2rem, 5vw, 4.6rem);
  line-height: 0.96;
  letter-spacing: -0.04em;
  overflow-wrap: anywhere;
}

.blog-list {
  display: grid;
  gap: 1px;
  padding: 0;
  background: rgba(240, 237, 230, 0.08);
}

.blog-card {
  display: grid;
  grid-template-columns: 130px 1fr;
  gap: 1.2rem;
  align-items: start;
  padding: 1.4rem;
  background: var(--bg);
  text-decoration: none;
  transition: background 180ms ease;
}

.blog-card:hover {
  background: var(--bg-2);
}

.blog-card time {
  font-family: var(--mono);
  color: var(--accent);
  font-size: 0.68rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.blog-card h3 {
  margin: 0 0 0.6rem;
  font-size: 1.25rem;
  letter-spacing: -0.02em;
}

.about-grid {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  gap: 1px;
  background: var(--soft-line);
}

.about-number {
  display: grid;
  place-items: center;
  min-height: 380px;
  background: var(--bg);
  font-size: clamp(7rem, 16vw, 15rem);
  font-weight: 800;
  line-height: 1;
  color: transparent;
  -webkit-text-stroke: 1px rgba(240, 237, 230, 0.16);
  letter-spacing: -0.06em;
}

.about-stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  margin-top: 2rem;
  background: var(--soft-line);
}

.about-stats div {
  padding: 1.3rem;
  background: var(--bg-2);
}

.stat-num {
  display: block;
  color: var(--accent);
  font-size: 2.2rem;
  font-weight: 800;
  letter-spacing: -0.03em;
}

.stat-label {
  display: block;
  margin-top: 0.35rem;
  font-family: var(--mono);
  color: var(--muted);
  font-size: 0.65rem;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.site-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1.5rem;
  padding: 2.2rem clamp(1.25rem, 4vw, 3rem);
  border-top: 1px solid var(--soft-line);
  font-family: var(--mono);
  color: var(--muted);
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

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

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

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 1.4rem;
}

.footer-social {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.7rem;
}

.social-link {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  min-height: 2rem;
  padding: 0.45rem 0.65rem;
  border: 1px solid var(--soft-line);
  color: var(--muted);
  background: rgba(255, 255, 255, 0.02);
  clip-path: polygon(0 0, calc(100% - 8px) 0, 100% 8px, 100% 100%, 8px 100%, 0 calc(100% - 8px));
  transition: color 160ms ease, border-color 160ms ease, background 160ms ease, transform 160ms ease;
}

.social-link:hover {
  color: var(--accent);
  border-color: var(--accent);
  background: rgba(225, 255, 45, 0.06);
  transform: translateY(-1px);
}

.social-glyph {
  width: 0.95rem;
  height: 0.95rem;
  flex: 0 0 auto;
  background: currentColor;
}

.x-glyph {
  mask: url("icons/social-x.svg") center / contain no-repeat;
  -webkit-mask: url("icons/social-x.svg") center / contain no-repeat;
}

.tiktok-glyph {
  mask: url("icons/social-tiktok.svg") center / contain no-repeat;
  -webkit-mask: url("icons/social-tiktok.svg") center / contain no-repeat;
}

.social-handle {
  color: var(--text);
}

.page-hero {
  min-height: 78dvh;
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(320px, 1.05fr);
  gap: clamp(2rem, 5vw, 5rem);
  align-items: center;
  max-width: var(--max);
  margin: 0 auto;
  padding: clamp(7rem, 13vh, 9rem) clamp(1.25rem, 4vw, 3rem) clamp(3rem, 7vh, 5rem);
}

.page-kicker {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
  margin-bottom: 1.4rem;
}

.page-visual {
  position: relative;
  min-height: 480px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--bg-2);
  clip-path: polygon(0 0, calc(100% - 24px) 0, 100% 24px, 100% 100%, 24px 100%, 0 calc(100% - 24px));
}

.paper-page {
  --accent: #cf413a;
  --bg: #f4f0e8;
  --bg-2: #fffaf0;
  --bg-3: #eee5d8;
  --fg: #191713;
  --muted: #756e62;
  --line: rgba(25, 23, 19, 0.15);
  --soft-line: rgba(25, 23, 19, 0.09);
}

.paper-page body,
body.paper-page {
  background: var(--bg);
}

.paper-sheet {
  position: absolute;
  inset: 2rem;
  background:
    repeating-linear-gradient(to bottom, transparent 0 28px, rgba(25, 23, 19, 0.16) 29px 31px),
    linear-gradient(105deg, rgba(207, 65, 58, 0.13), transparent 45%),
    var(--bg-2);
  border: 1px solid rgba(25, 23, 19, 0.16);
  transform: rotate(-2deg);
}

.paper-sheet::before {
  content: "PaperWave";
  position: absolute;
  left: 1.2rem;
  top: 1rem;
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  color: var(--accent);
  text-transform: uppercase;
}

.paper-note {
  position: absolute;
  right: 2.4rem;
  bottom: 2.4rem;
  width: 130px;
  height: 130px;
  border: 12px solid var(--fg);
  border-left: 0;
  border-top: 0;
  border-radius: 0 0 60px 0;
  transform: rotate(-12deg);
}

.paper-note::before {
  content: "";
  position: absolute;
  left: -38px;
  bottom: -30px;
  width: 52px;
  height: 38px;
  background: var(--fg);
  border-radius: 50%;
}

.peekr-page {
  --accent: #d7c26b;
  --danger: #f05b55;
  --bg: #09140f;
  --bg-2: #0f2018;
  --bg-3: #162b21;
  --fg: #f3ead7;
  --muted: #9d9a87;
  --line: rgba(243, 234, 215, 0.15);
  --soft-line: rgba(243, 234, 215, 0.08);
}

.felt-table {
  position: absolute;
  inset: 2rem;
  display: grid;
  place-items: center;
  border: 18px solid #312016;
  border-radius: 44%;
  background:
    radial-gradient(ellipse at center, rgba(215, 194, 107, 0.12), transparent 60%),
    repeating-linear-gradient(45deg, rgba(255, 255, 255, 0.035) 0 1px, transparent 1px 8px),
    #123322;
}

.felt-table::before {
  content: "IN DEVELOPMENT";
  font-family: var(--mono);
  color: var(--accent);
  letter-spacing: 0.2em;
  font-size: 0.75rem;
}

html[lang="zh-CN"] .felt-table::before {
  content: "开发中";
}

html[lang="zh-Hant"] .felt-table::before {
  content: "開發中";
}

html[lang="ja"] .felt-table::before {
  content: "開発中";
}

html[lang="es"] .felt-table::before {
  content: "EN DESARROLLO";
}

html[lang="fr"] .felt-table::before {
  content: "EN DÉVELOPPEMENT";
}

.playing-card {
  position: absolute;
  width: 74px;
  height: 104px;
  display: grid;
  place-items: center;
  background: #f5eee2;
  color: #101014;
  border: 1px solid rgba(0, 0, 0, 0.28);
  border-radius: 8px;
  font-family: var(--mono);
  font-weight: 700;
}

.playing-card.a {
  left: 26%;
  top: 28%;
  transform: rotate(-10deg);
}

.playing-card.k {
  right: 27%;
  bottom: 28%;
  transform: rotate(8deg);
  color: #b6262c;
}

.melodot-page {
  --accent: #e4f84e;
  --danger: #ff6b5f;
  --cyan: #6fd6ff;
  --bg: #0a0a0c;
  --bg-2: #12121d;
  --bg-3: #181824;
  --fg: #f0ede6;
  --muted: #8a8880;
}

.melody-board {
  position: absolute;
  inset: 2rem;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  grid-template-rows: repeat(5, 1fr);
  gap: 8px;
  padding: 1rem;
  background:
    repeating-linear-gradient(to bottom, transparent 0 34px, rgba(240, 237, 230, 0.12) 35px 37px),
    #101014;
}

.melody-board span {
  border: 1px solid rgba(240, 237, 230, 0.16);
  background: rgba(240, 237, 230, 0.04);
}

.melody-board .hot {
  background: var(--accent);
}

.melody-board .warm {
  background: var(--danger);
}

.melody-board .cool {
  background: var(--cyan);
}

.listing {
  max-width: 980px;
  margin: 0 auto;
  padding: clamp(7rem, 13vh, 9rem) clamp(1.25rem, 4vw, 3rem) clamp(4rem, 8vw, 6rem);
}

.listing h1 {
  margin: 0 0 1.6rem;
  font-size: clamp(3rem, 8vw, 7rem);
  line-height: 0.9;
  letter-spacing: -0.045em;
}

.listing-grid {
  display: grid;
  gap: 1px;
  margin-top: 3rem;
  background: var(--soft-line);
}

.listing-item {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 1.2rem;
  padding: 1.4rem;
  background: var(--bg);
  text-decoration: none;
}

.listing-item:hover {
  background: var(--bg-2);
}

.listing-item time,
.listing-item .idea-state {
  font-family: var(--mono);
  color: var(--accent);
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.listing-item h2 {
  margin: 0 0 0.6rem;
  font-size: 1.4rem;
  letter-spacing: -0.02em;
}

.listing-item p {
  margin: 0;
  font-family: var(--mono);
  color: var(--muted);
  font-size: 0.8rem;
  line-height: 1.7;
}

.reveal {
  opacity: 0;
  transform: translate3d(0, 22px, 0);
  transition: opacity 560ms ease, transform 560ms ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translate3d(0, 0, 0);
}

@keyframes marquee {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(-50%);
  }
}

@keyframes glitch {
  0% {
    text-shadow: 2px 0 var(--danger), -2px 0 var(--accent);
  }
  40% {
    text-shadow: -2px 0 var(--danger), 2px 0 var(--accent);
  }
  70% {
    text-shadow: 2px 0 var(--accent), -2px 0 var(--danger);
  }
  100% {
    text-shadow: none;
  }
}

@media (max-width: 900px) {
  .hero,
  .page-hero,
  .work-grid,
  .blog-strip,
  .about-grid {
    grid-template-columns: 1fr;
  }

  .page-visual {
    min-height: 410px;
  }

  .work-card {
    min-height: 420px;
  }

  .blog-card,
  .listing-item {
    grid-template-columns: 1fr;
  }

  .about-number {
    display: none;
  }
}

@media (max-width: 680px) {
  .topbar {
    align-items: flex-start;
  }

  .nav-links {
    gap: 0.85rem;
    font-size: 0.64rem;
  }

  .lang-button {
    min-width: 4rem;
    min-height: 28px;
    padding: 0.28rem 0.48rem;
    font-size: 0.62rem;
  }

  .lang-list {
    right: -0.2rem;
    width: min(12rem, calc(100vw - 1.5rem));
  }

  .nav-links a:nth-child(3) {
    display: none;
  }

  .hero {
    padding-top: 6rem;
  }

  :is(html[lang="zh-CN"], html[lang="zh-Hant"], html[lang="ja"]) .hero {
    align-items: end;
    padding-top: 6rem;
    padding-bottom: 3rem;
  }

  :is(html[lang="zh-CN"], html[lang="zh-Hant"], html[lang="ja"]) .hero h1 {
    max-width: 100%;
    font-size: clamp(3.6rem, 15vw, 4.1rem);
    line-height: 0.94;
  }

  :is(html[lang="zh-CN"], html[lang="zh-Hant"], html[lang="ja"]) .hero-copy {
    margin-top: 2.1rem;
    line-height: 1.9;
  }

  :is(html[lang="zh-CN"], html[lang="zh-Hant"], html[lang="ja"]) .hero-actions {
    margin-top: 2.65rem;
  }

  .hero h1,
  .page-hero h1,
  .listing h1 {
    font-size: clamp(2.25rem, 8.5vw, 3rem);
    overflow-wrap: normal;
  }

  .about-stats {
    grid-template-columns: 1fr;
  }

  .site-footer {
    flex-direction: column;
    align-items: flex-start;
  }

  .footer-social {
    justify-content: flex-start;
  }
}

@media (hover: none), (pointer: coarse) {
  .pixel-cursor {
    display: none;
  }
}

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

  .pixel-cursor {
    display: none;
  }
}
