/* ============================================================
   CSYVII — 正式样式
   暖白纸底 / 深灰墨字 / 暗陶棕点缀
   Editorial · Archive · Contemporary
   ============================================================ */

/* ---------- 字体 ---------- */

@font-face {
  font-family: "Cormorant Garamond";
  src: url("../assets/fonts/CormorantGaramond-Variable.woff2") format("woff2-variations");
  font-weight: 300 700;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Noto Serif SC";
  src: url("../assets/fonts/NotoSerifSC-subset.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}

@font-face {
  font-family: "Noto Sans SC";
  src: url("../assets/fonts/NotoSansSC-subset.woff2") format("woff2");
  font-weight: 300;
  font-display: swap;
}

@font-face {
  font-family: "LXGW WenKai";
  src: url("../assets/fonts/LXGWWenKai-subset.woff2") format("woff2");
  font-weight: 400;
  font-display: swap;
}

/* ---------- token ---------- */

:root {
  --paper:      #F6F3EE;
  --paper-deep: #EDE7DD;
  --ink:        #1F1D1A;
  --ink-2:      #5A554D;
  --ink-3:      #867F74;
  --clay:       #8A5A3B;
  --clay-deep:  #6B4229;
  --rule:       #DBD3C6;
  --rule-soft:  #E7E0D4;

  --page:   1240px;
  --gutter: 40px;

  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

/* ---------- reset ---------- */

*, *::before, *::after { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "Noto Sans SC", "Cormorant Garamond", serif;
  font-weight: 300;
  font-size: 16px;
  line-height: 1.85;
  letter-spacing: 0.01em;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

img, video { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
ul, ol, dl, dd { margin: 0; padding: 0; }
li { list-style: none; }
p { margin: 0; }
figure { margin: 0; }
h1, h2, h3, h4 { margin: 0; font-weight: 400; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* ---------- 排版基元 ---------- */

.wrap {
  width: 100%;
  max-width: calc(var(--page) + var(--gutter) * 2);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

/* 小号标签：编号、元信息、栏目标记 */
.label {
  font-family: "Noto Sans SC", sans-serif;
  font-weight: 300;
  font-size: 11.5px;
  line-height: 1.6;
  letter-spacing: 0.16em;
  color: var(--ink-3);
  text-transform: uppercase;
}

.label--clay { color: var(--clay); }

/* 英文小标题 */
.en {
  font-family: "Cormorant Garamond", serif;
  font-weight: 300;
  font-size: 13px;
  letter-spacing: 0.12em;
  color: var(--ink-3);
  text-transform: uppercase;
}

/* 中文标题 */
.zh-title {
  font-family: "Noto Serif SC", serif;
  font-weight: 400;
  letter-spacing: 0.02em;
  line-height: 1.28;
}

/* 分隔线 */
.rule {
  height: 1px;
  background: var(--rule);
  border: 0;
  margin: 0;
}

/* ---------- 页头 ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: color-mix(in srgb, var(--paper) 88%, transparent);
  backdrop-filter: saturate(140%) blur(12px);
  border-bottom: 1px solid var(--rule-soft);
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.brand {
  font-family: "Cormorant Garamond", serif;
  font-weight: 400;
  font-size: 19px;
  letter-spacing: 0.22em;
  color: var(--ink);
}

.nav {
  display: flex;
  align-items: center;
  gap: 30px;
}

.nav a {
  font-size: 13px;
  letter-spacing: 0.08em;
  color: var(--ink-2);
  padding: 4px 0;
  border-bottom: 1px solid transparent;
  transition: color 0.35s var(--ease), border-color 0.35s var(--ease);
}

.nav a:hover { color: var(--clay); border-bottom-color: var(--clay); }

.nav .lang {
  font-family: "Cormorant Garamond", serif;
  font-size: 13px;
  letter-spacing: 0.16em;
  color: var(--clay);
  border-left: 1px solid var(--rule);
  padding-left: 30px;
  margin-left: 6px;
}

/* ---------- Hero ---------- */

.hero { padding-top: 88px; }

.hero-eyebrow {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 34px;
}

.hero-eyebrow::before {
  content: "";
  width: 34px;
  height: 1px;
  background: var(--clay);
}

.hero h1 {
  font-family: "Noto Serif SC", serif;
  font-weight: 400;
  font-size: clamp(28px, 3.9vw, 50px);
  line-height: 1.34;
  letter-spacing: 0.02em;
  max-width: 17em;
  margin-bottom: 40px;
}

.hero h1 em {
  font-style: normal;
  color: var(--clay);
}

.hero-figure {
  position: relative;
  overflow: hidden;
  background: var(--paper-deep);
}

.hero-figure img {
  width: 100%;
  /* 必须有 height:auto，否则 <img> 的 height 属性会把框撑成原图高，aspect-ratio 失效 */
  height: auto;
  aspect-ratio: 21 / 9;
  object-fit: cover;
}

.hero-caption {
  position: absolute;
  left: 0;
  bottom: 0;
  display: flex;
  align-items: baseline;
  gap: 14px;
  padding: 14px 18px;
  background: color-mix(in srgb, var(--paper) 92%, transparent);
  backdrop-filter: blur(6px);
}

.hero-caption .t { font-family: "Noto Serif SC", serif; font-size: 13px; color: var(--ink); }
.hero-caption .d { font-size: 11.5px; letter-spacing: 0.12em; color: var(--ink-3); }

.hero-foot {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 40px;
  padding-top: 22px;
}

.hero-foot p {
  font-size: 13.5px;
  color: var(--ink-2);
  max-width: 34em;
}

/* ---------- 章节 ---------- */

.section { padding-top: 120px; }

.section-head {
  display: flex;
  align-items: baseline;
  gap: 18px;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--rule);
  margin-bottom: 64px;
}

.section-head .num {
  font-family: "Cormorant Garamond", serif;
  font-size: 13px;
  letter-spacing: 0.16em;
  color: var(--clay);
}

.section-head h2 {
  font-size: 12px;
  font-weight: 400;
  letter-spacing: 0.22em;
  color: var(--ink-2);
  text-transform: uppercase;
  font-family: "Noto Sans SC", sans-serif;
}

/* ---------- 作品通用 ---------- */

.work {
  padding-bottom: 140px;
}

.work:last-child { padding-bottom: 0; }

.work-head {
  display: grid;
  grid-template-columns: 88px 1fr auto;
  gap: 0 24px;
  align-items: end;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--rule-soft);
  margin-bottom: 34px;
}

.work-index {
  font-family: "Cormorant Garamond", serif;
  font-weight: 300;
  font-size: 46px;
  line-height: 0.86;
  color: var(--clay);
  letter-spacing: 0.04em;
}

.work-title h3 {
  font-family: "Noto Serif SC", serif;
  font-size: clamp(21px, 2.1vw, 27px);
  line-height: 1.3;
  letter-spacing: 0.02em;
}

.work-title .en {
  margin-top: 7px;
  display: block;
}

.work-meta {
  font-size: 11.5px;
  line-height: 1.8;
  letter-spacing: 0.04em;
  color: var(--ink-3);
  text-align: right;
  white-space: nowrap;
}

.work-body {
  display: grid;
  grid-template-columns: 1fr 360px;
  gap: 0 64px;
  align-items: start;
  margin-top: 34px;
}

.work-desc {
  font-size: 15px;
  line-height: 1.9;
  color: var(--ink-2);
  max-width: 34em;
}

.work-note {
  font-size: 12.5px;
  line-height: 1.8;
  color: var(--ink-3);
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid var(--rule-soft);
  max-width: 32em;
}

.work-note b { font-weight: 400; color: var(--clay); }

/* 图片容器 */
.frame {
  position: relative;
  overflow: hidden;
  background: var(--paper-deep);
}

.frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 1.1s var(--ease);
}

a.frame:hover img { transform: scale(1.02); }

/* 图片角标 */
.frame-tag {
  position: absolute;
  left: 0;
  bottom: 0;
  padding: 9px 14px;
  font-size: 11px;
  letter-spacing: 0.14em;
  color: var(--ink-2);
  background: color-mix(in srgb, var(--paper) 90%, transparent);
  backdrop-filter: blur(4px);
}

/* 链接动作 */
.act {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 12.5px;
  letter-spacing: 0.12em;
  color: var(--clay);
  padding-bottom: 3px;
  border-bottom: 1px solid color-mix(in srgb, var(--clay) 38%, transparent);
  transition: gap 0.4s var(--ease), border-color 0.4s var(--ease);
}

.act::after { content: "→"; font-family: "Cormorant Garamond", serif; font-size: 15px; }
.act:hover { gap: 16px; border-bottom-color: var(--clay); }

/* ---------- 01 整幅 ---------- */

.work--wide .frame img { aspect-ratio: 16 / 9; }

.work--wide .work-body {
  grid-template-columns: minmax(0, 1fr) 380px;
  gap: 0 56px;
}

/* 侧注和入口都在右栏，顶端与左栏第一行对齐 */
.work--wide .work-body > div:last-child .work-note { margin-top: 0; }

/* ---------- 02 左右分栏 ---------- */

.work--split .work-body { grid-template-columns: 1fr 1fr; gap: 0 56px; }
.work--split .frame img { aspect-ratio: 16 / 9; }

.episode-list {
  margin-top: 26px;
  border-top: 1px solid var(--rule-soft);
}

.episode-list li {
  display: grid;
  grid-template-columns: 62px 1fr auto;
  gap: 12px;
  align-items: baseline;
  padding: 12px 0;
  border-bottom: 1px solid var(--rule-soft);
  font-size: 13.5px;
  color: var(--ink-2);
}

.episode-list .ep-no {
  font-family: "Cormorant Garamond", serif;
  font-size: 12.5px;
  letter-spacing: 0.06em;
  color: var(--clay);
}

.episode-list .ep-len {
  font-size: 11.5px;
  letter-spacing: 0.1em;
  color: var(--ink-3);
}

.episode-list li[aria-current] span:nth-child(2) { color: var(--ink); }

/* ---------- 03 剪辑 ---------- */

.work--edits .work-body {
  grid-template-columns: 1fr 340px;
  gap: 0 56px;
}

.edit-row {
  display: grid;
  grid-template-columns: 6fr 3fr 2fr;
  gap: 20px;
  align-items: start;
}

.edit-item { position: relative; display: block; }

.edit-item .frame img { aspect-ratio: auto; height: 100%; }

.edit-item:nth-child(1) .frame { aspect-ratio: 16 / 9; margin-top: 44px; }
.edit-item:nth-child(2) .frame { aspect-ratio: 3 / 4; }
.edit-item:nth-child(3) .frame { aspect-ratio: 9 / 16; margin-top: 24px; }

.edit-cap {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 10px;
  margin-top: 10px;
  font-size: 11.5px;
  letter-spacing: 0.1em;
  color: var(--ink-3);
}

.edit-cap .n { color: var(--ink-2); }

.alt-list {
  margin-top: 24px;
  border-top: 1px solid var(--rule-soft);
}

.alt-list li {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 11px 0;
  border-bottom: 1px solid var(--rule-soft);
  font-size: 13px;
  color: var(--ink-2);
}

.alt-list .len { color: var(--ink-3); font-size: 11.5px; letter-spacing: 0.1em; }

/* ---------- 04 未完成 ---------- */

.work--future .work-head { border-bottom-color: var(--rule-soft); }

.work--future .work-index { color: var(--ink-3); opacity: 0.55; }

.badge {
  font-size: 10.5px;
  letter-spacing: 0.18em;
  color: var(--ink-3);
  border: 1px solid var(--rule);
  padding: 5px 10px;
  white-space: nowrap;
}

.future-block {
  display: grid;
  grid-template-columns: 1fr 380px;
  gap: 0 64px;
  align-items: start;
}

.future-plate {
  aspect-ratio: 16 / 7;
  background: var(--paper-deep);
  border: 1px solid var(--rule-soft);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--ink-3);
  font-size: 12px;
  letter-spacing: 0.2em;
}

.work--future .work-desc { color: var(--ink-3); }

/* ---------- About ---------- */

.about-body {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 80px;
  align-items: start;
}

.about-text p {
  font-size: 15px;
  line-height: 1.9;
  color: var(--ink-2);
  max-width: 30em;
}

.about-text p + p { margin-top: 20px; }

.about-lede {
  font-family: "Noto Serif SC", serif;
  font-size: clamp(19px, 1.9vw, 23px) !important;
  line-height: 1.7 !important;
  color: var(--ink) !important;
  letter-spacing: 0.02em;
}

.about-sign {
  font-family: "LXGW WenKai", serif;
  font-size: 15px;
  color: var(--clay);
  margin-top: 28px;
}

.about-facts {
  border-top: 1px solid var(--rule);
}

.about-facts > div {
  display: grid;
  grid-template-columns: 90px 1fr;
  gap: 20px;
  padding: 13px 0;
  border-bottom: 1px solid var(--rule-soft);
}

.about-facts dt {
  font-size: 11.5px;
  letter-spacing: 0.14em;
  color: var(--ink-3);
}

.about-facts dd {
  font-size: 13.5px;
  color: var(--ink-2);
}

/* ---------- Contact ---------- */

.contact {
  padding-top: 120px;
  padding-bottom: 140px;
}

.contact-line {
  font-family: "Noto Serif SC", serif;
  font-size: clamp(20px, 2.4vw, 30px);
  line-height: 1.6;
  letter-spacing: 0.02em;
  max-width: 22em;
  margin-bottom: 44px;
}

.contact-mail {
  display: inline-block;
  font-family: "Cormorant Garamond", serif;
  font-size: clamp(22px, 2.8vw, 34px);
  letter-spacing: 0.02em;
  /* 邮箱里的数字必须站直：Cormorant 默认旧式数字，1 看着像小写 l */
  font-variant-numeric: lining-nums;
  color: var(--clay);
  border-bottom: 1px solid color-mix(in srgb, var(--clay) 30%, transparent);
  padding-bottom: 6px;
  transition: border-color 0.4s var(--ease), color 0.4s var(--ease);
}

.contact-mail:hover { color: var(--clay-deep); border-bottom-color: var(--clay-deep); }

.contact-note {
  margin-top: 26px;
  font-size: 12px;
  line-height: 1.9;
  color: var(--ink-3);
  letter-spacing: 0.04em;
}

/* ---------- 页脚 ---------- */

.site-footer {
  border-top: 1px solid var(--rule);
  padding: 30px 0 44px;
}

.site-footer .wrap {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 24px;
  flex-wrap: wrap;
}

.site-footer span {
  font-size: 11.5px;
  letter-spacing: 0.12em;
  color: var(--ink-3);
}

.site-footer .fbrand {
  font-family: "Cormorant Garamond", serif;
  font-size: 13px;
  letter-spacing: 0.26em;
  color: var(--ink-2);
}

/* ---------- 响应式 ---------- */

@media (max-width: 1080px) {
  :root { --gutter: 32px; }
  .work-body,
  .work--wide .work-body,
  .work--split .work-body,
  .work--edits .work-body,
  .future-block,
  .about-body { grid-template-columns: 1fr; gap: 34px; }
  .work-meta { text-align: left; white-space: normal; }
  .work-head { grid-template-columns: 64px 1fr; }
  .work-head .work-meta { grid-column: 2; text-align: left; margin-top: 8px; }
}

@media (max-width: 720px) {
  :root { --gutter: 22px; }

  .site-header .wrap { height: 62px; }
  .nav { gap: 18px; }
  .nav a { font-size: 12px; }
  .nav .lang { padding-left: 18px; }

  .hero { padding-top: 56px; }
  .hero h1 { font-size: 28px; margin-bottom: 28px; }
  .hero-eyebrow { margin-bottom: 24px; }
  /* 21:9 在手机上空成一条横幅，收成 16:9 */
  .hero-figure img { aspect-ratio: 16 / 9; }
  .hero-foot { flex-direction: column; align-items: flex-start; gap: 10px; }

  .section { padding-top: 64px; }
  .section-head { margin-bottom: 44px; }
  .work { padding-bottom: 80px; }

  .work-index { font-size: 34px; }
  .work-title h3 { font-size: 20px; }
  .work-desc { font-size: 14px; }

  .edit-row {
    gap: 10px;
    grid-template-columns: 1fr 1fr;
  }
  .edit-item:nth-child(2) .frame,
  .edit-item:nth-child(3) .frame { margin-top: 0; }
  .edit-item:nth-child(3) { grid-column: 1 / -1; }
  .edit-item:nth-child(3) .frame { aspect-ratio: 16 / 9; }

  .future-plate { aspect-ratio: 3 / 2; }

  .contact { padding-top: 64px; padding-bottom: 80px; }
  .contact-line { margin-bottom: 30px; }

  .site-footer .wrap { flex-direction: column; gap: 10px; }
}
