:root {
  --bg: #f3f3f3;
  --ink: #090909;
  --body: #2f2f2f;
  --muted: #7a7a7a;
  --soft: #5c5c5c;
  --accent: #a6008a;
  --rule: #dedede;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: "Avenir Next", Avenir, "Helvetica Neue", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

.accent {
  position: fixed;
  z-index: 30;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--accent);
}

.nav {
  position: fixed;
  z-index: 25;
  top: 42px;
  right: 5.6vw;
  display: flex;
  align-items: center;
  gap: 12px;
}
.nav a {
  color: var(--ink);
  text-decoration: none;
  font-size: 16px;
  font-weight: 600;
  padding: 7px 15px;
}
.nav a.active { background: #292929; color: #fff; }

.section-rule { border-bottom: 1px solid var(--rule); }

/* About hero — portrait crop comes directly from the approved Wix screenshot. */
.hero { min-height: 100vh; display: flex; align-items: center; }
.hero-inner {
  width: 100%;
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(440px, .92fr);
  align-items: center;
  gap: 5vw;
  padding: 9vh 10.5vw 6vh 12.6vw;
}
.hero-copy { align-self: center; padding-top: 2vh; }
.hero h1 {
  margin: 0 0 68px;
  font-family: Arial, "Helvetica Neue", sans-serif;
  font-size: clamp(76px, 7.2vw, 118px);
  line-height: 1.14;
  letter-spacing: -.045em;
  font-weight: 800;
}
.hero-tagline,
.hero-hello {
  margin: 0;
  font-family: Arial, "Helvetica Neue", sans-serif;
  font-size: clamp(21px, 1.62vw, 29px);
  line-height: 1.35;
  font-weight: 700;
}
.hero-tagline { margin-bottom: 62px; }
.portrait-wrap {
  width: min(100%, 590px);
  justify-self: center;
  overflow: hidden;
  background: var(--bg);
}
.portrait-wrap img {
  width: 100%;
  height: auto;
  display: block;
  background: var(--bg);
}

/* About sections */
.about-row {
  display: grid;
  grid-template-columns: 34% 66%;
  gap: 8vw;
  padding: 8vh 12vw;
}
.about-row > h2 {
  margin: 0;
  font-family: Arial, "Helvetica Neue", sans-serif;
  font-size: clamp(38px, 3vw, 56px);
  line-height: 1.08;
  font-weight: 750;
}
.about-copy {
  max-width: 820px;
  color: var(--body);
  font-size: clamp(17px, 1.25vw, 22px);
  line-height: 1.72;
}
.about-copy ul { margin: 0; padding-left: 1.05em; }
.about-copy li { margin: 0; }
.about-copy p { margin: 0 0 42px; }
a { color: inherit; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.audio-line { display: flex; align-items: center; gap: 18px; margin: 34px 0 48px; white-space: nowrap; }
.audio-line audio { width: 150px; height: 32px; }

/* Footer */
.footer {
  border-top: 1px solid var(--rule);
  padding: 28px 24px 36px;
  text-align: center;
  color: var(--body);
}
.coffee-line {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 12px;
  font-size: 16px;
  line-height: 1.35;
}
.coffee-line span { white-space: nowrap; }
.coffee-line a {
  display: inline-block;
  font-size: 20px;
  line-height: 1.2;
  font-weight: 700;
  color: #222;
  text-decoration-thickness: 1.5px;
  text-underline-offset: 5px;
}
.coffee-line a:hover { opacity: .62; }
.socials { margin-top: 30px; display: flex; justify-content: center; gap: 34px; }
.socials a { text-decoration: none; font-size: 15px; }
.socials a:hover { text-decoration: underline; }

/* Writing */
.writing-page { padding: 16vh 10.5vw 0; min-height: 100vh; color: var(--soft); }
.writing-header {
  display: grid;
  grid-template-columns: 34% 66%;
  gap: 8vw;
  align-items: end;
  padding-bottom: 64px;
}
.writing-header h1 {
  margin: 0;
  color: #272727;
  font-family: Arial, "Helvetica Neue", sans-serif;
  font-size: clamp(66px, 6.8vw, 108px);
  line-height: .96;
  letter-spacing: -.045em;
  font-weight: 800;
}
.writing-header p { margin: 0 0 6px; color: #8a8a8a; font-size: 18px; }

.writing-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6vw;
  border-top: 1px solid #cfcfcf;
  padding-bottom: 90px;
}
.writing-column { min-width: 0; }
.chinese-column { border-left: 1px solid #d8d8d8; padding-left: 6vw; }
.column-title {
  margin: 0;
  height: 84px;
  display: flex;
  align-items: center;
  border-bottom: 1px solid #d8d8d8;
  color: #686868;
  font-family: Arial, "Helvetica Neue", sans-serif;
  font-size: 26px;
  font-weight: 650;
}
.article-card {
  display: grid;
  grid-template-columns: 132px minmax(0, 1fr);
  gap: 24px;
  align-items: start;
  padding: 31px 0 34px;
  border-bottom: 1px solid #d9d9d9;
  color: inherit;
  text-decoration: none;
}
.article-card > img {
  width: 132px;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  display: block;
  opacity: .9;
  transition: transform .25s ease, opacity .25s ease;
}
.article-text time {
  display: block;
  margin: 0 0 8px;
  color: #a8a8a8;
  font-size: 11px;
  letter-spacing: .1em;
}
.article-text h3 {
  margin: 0 0 9px;
  color: #505050;
  font-family: Arial, "Helvetica Neue", sans-serif;
  font-size: clamp(22px, 1.6vw, 29px);
  line-height: 1.23;
  letter-spacing: -.015em;
  font-weight: 600;
  transition: color .2s ease;
}
.article-text p { margin: 0; color: #8a8a8a; font-size: 14px; line-height: 1.55; }
.article-card:hover > img { transform: scale(1.02); opacity: 1; }
.article-card:hover h3 { color: #8e3c7f; }
.chinese-column .article-text h3 {
  font-family: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans CJK SC", sans-serif;
  line-height: 1.35;
  letter-spacing: 0;
  font-weight: 560;
}
.chinese-column .article-text p {
  font-family: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans CJK SC", sans-serif;
}
.writing-footer { margin-left: -10.5vw; margin-right: -10.5vw; }

@media (max-width: 980px) {
  .hero-inner { grid-template-columns: 1.1fr .9fr; padding-left: 8vw; padding-right: 8vw; }
  .portrait-wrap { width: min(100%, 500px); }
  .article-card { grid-template-columns: 108px minmax(0,1fr); gap: 18px; }
  .article-card > img { width: 108px; }
}

@media (max-width: 760px) {
  .accent { height: 3px; }
  .nav { top: 24px; right: 18px; }
  .nav a { font-size: 14px; padding: 6px 11px; }

  .hero { min-height: auto; }
  .hero-inner { grid-template-columns: 1fr; gap: 34px; padding: 128px 28px 64px; }
  .hero h1 { font-size: 64px; margin-bottom: 44px; }
  .hero-tagline, .hero-hello { font-size: 20px; }
  .hero-tagline { margin-bottom: 36px; }
  .portrait-wrap { justify-self: start; width: min(100%, 420px); }

  .about-row { min-height: auto; grid-template-columns: 1fr; gap: 28px; padding: 70px 28px; }
  .about-row > h2 { font-size: 38px; }
  .about-copy { font-size: 17px; line-height: 1.68; }
  .audio-line { white-space: normal; flex-wrap: wrap; }

  .coffee-line { gap: 10px; font-size: 13px; }
  .coffee-line span { white-space: normal; }
  .coffee-line a { font-size: 19px; }
  .socials { gap: 22px; flex-wrap: wrap; }

  .writing-page { padding: 128px 28px 0; }
  .writing-header { grid-template-columns: 1fr; gap: 24px; padding-bottom: 48px; }
  .writing-header h1 { font-size: 64px; }
  .writing-grid { grid-template-columns: 1fr; gap: 0; }
  .chinese-column { border-left: 0; padding-left: 0; margin-top: 64px; border-top: 1px solid #cfcfcf; }
  .article-card { grid-template-columns: 104px minmax(0,1fr); gap: 18px; padding: 26px 0; }
  .article-card > img { width: 104px; }
  .article-text h3 { font-size: 23px; }
  .article-text p { font-size: 13px; }
  .writing-footer { margin-left: -28px; margin-right: -28px; }
}

/* Custom Pipa player — visually matches the original Wix treatment */
.audio-line audio { display: none; }
.pipa-play {
  width: 30px;
  height: 30px;
  padding: 0;
  border: 0;
  background: transparent;
  display: inline-grid;
  place-items: center;
  cursor: pointer;
}
.play-triangle {
  width: 0;
  height: 0;
  border-top: 9px solid transparent;
  border-bottom: 9px solid transparent;
  border-left: 15px solid #222;
  margin-left: 3px;
}
.pipa-play.is-playing .play-triangle {
  width: 13px;
  height: 17px;
  border: 0;
  margin-left: 0;
  background: linear-gradient(to right, #222 0 38%, transparent 38% 62%, #222 62% 100%);
}
.pipa-progress {
  width: 92px;
  height: 4px;
  border-radius: 999px;
  background: #c9c9c9;
  overflow: hidden;
  cursor: pointer;
}
.pipa-progress span {
  display: block;
  width: 0;
  height: 100%;
  background: #222;
}


/* Social / WeChat */
.socials button.wechat-link {
  border: 0;
  padding: 0;
  margin: 0;
  background: transparent;
  color: inherit;
  font: inherit;
  font-size: 15px;
  cursor: pointer;
}
.socials button.wechat-link:hover { text-decoration: underline; text-underline-offset: 3px; }
.wechat-modal {
  position: fixed;
  inset: 0;
  z-index: 80;
  display: grid;
  place-items: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity .18s ease;
}
.wechat-modal.is-open { opacity: 1; pointer-events: auto; }
.wechat-backdrop {
  position: absolute;
  inset: 0;
  border: 0;
  background: rgba(18,18,18,.32);
  backdrop-filter: blur(4px);
  cursor: pointer;
}
.wechat-card {
  position: relative;
  z-index: 1;
  width: min(360px, calc(100vw - 40px));
  padding: 34px 34px 30px;
  background: #f7f7f7;
  box-shadow: 0 18px 70px rgba(0,0,0,.16);
  text-align: center;
}
.wechat-card p {
  margin: 0 0 18px;
  font-family: Arial, "Helvetica Neue", sans-serif;
  font-size: 24px;
  font-weight: 700;
  color: #333;
}
.wechat-card img {
  display: block;
  width: 230px;
  max-width: 100%;
  margin: 0 auto 17px;
  background: #fff;
}
.wechat-card span { color: #777; font-size: 13px; }
.wechat-close {
  position: absolute;
  top: 8px;
  right: 12px;
  border: 0;
  background: transparent;
  color: #777;
  font: 300 28px/1 Arial, sans-serif;
  cursor: pointer;
}

/* Writing: compact editorial cards for a growing archive */
.writing-grid { align-items: start; }
.article-card { min-height: 150px; }
.article-text h3 { margin-top: 2px; }
.chinese-column .article-card { grid-template-columns: 112px minmax(0, 1fr); gap: 22px; }
.chinese-column .article-card > img { width: 112px; }
.chinese-column .article-text h3 { font-size: clamp(20px, 1.4vw, 25px); color: #555; }
@media (max-width: 760px) {
  .socials button.wechat-link { font-size: 15px; }
  .chinese-column .article-card { grid-template-columns: 92px minmax(0, 1fr); gap: 16px; }
  .chinese-column .article-card > img { width: 92px; }
}
