:root {
  --paper: #fffcf7;
  --paper-deep: #f8f1e6;
  --ink: #4a3a2e;
  --ink-soft: #8a7767;
  --line: #eee2d2;
  --accent: #c8804f;
  --accent-deep: #b06c3e;
  --accent-soft: #fbeee1;
  --sage: #7d9b86;
  --sage-soft: #eef3ec;
  --serif: Georgia, "Songti SC", "SimSun", serif;
  --sans: "Microsoft YaHei", "PingFang SC", system-ui, sans-serif;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background:
    radial-gradient(900px 440px at 10% -10%, rgba(255, 222, 184, .55), transparent 70%),
    radial-gradient(720px 400px at 92% 2%, rgba(210, 230, 212, .45), transparent 72%),
    var(--paper);
  background-attachment: fixed;
  color: var(--ink);
  font: 16px/1.75 var(--sans);
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }

/* ---------- 顶部 ---------- */
.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1040px;
  margin: 0 auto;
  padding: 26px 28px;
}

.brand {
  font: 600 15px/1 var(--serif);
  letter-spacing: .14em;
  color: var(--ink);
}

.top nav {
  display: flex;
  gap: 26px;
  font-size: 13px;
  letter-spacing: .1em;
  color: var(--ink-soft);
}

.top nav a {
  position: relative;
  padding-bottom: 3px;
  transition: color .2s ease;
}

.top nav a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 0;
  height: 1px;
  background: var(--accent);
  transition: width .25s ease;
}

.top nav a:hover::after { width: 100%; }
.top nav a:hover { color: var(--accent-deep); }

/* ---------- 首屏 ---------- */
main {
  max-width: 1040px;
  margin: 0 auto;
  padding: 0 28px 48px;
}

.hero {
  position: relative;
  padding: clamp(64px, 13vh, 140px) 0 clamp(76px, 14vh, 150px);
  border-bottom: 1px solid var(--line);
}

.hero::after {
  content: "";
  position: absolute;
  right: clamp(0px, 4vw, 60px);
  top: clamp(40px, 9vh, 90px);
  width: clamp(90px, 13vw, 150px);
  height: clamp(90px, 13vw, 150px);
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #ffe3c2, rgba(255, 227, 194, .08) 72%);
  filter: blur(16px);
  opacity: .6;
  pointer-events: none;
}

.eyebrow {
  margin: 0 0 22px;
  font: 11px/1 var(--sans);
  letter-spacing: .28em;
  color: var(--accent);
  text-transform: uppercase;
}

.hero h1 {
  margin: 0;
  font: 400 clamp(34px, 6vw, 60px)/1.3 var(--serif);
  letter-spacing: .02em;
  color: #42332a;
}

.lede {
  max-width: 30em;
  margin: 26px 0 34px;
  font-size: 16px;
  color: var(--ink-soft);
}

.cta {
  display: inline-block;
  padding: 12px 26px;
  border-radius: 999px;
  background: var(--accent);
  color: #fffaf3;
  font-size: 14px;
  letter-spacing: .06em;
  box-shadow: 0 8px 20px rgba(200, 128, 79, .22);
  transition: transform .2s ease, box-shadow .2s ease, background .2s ease;
}

.cta:hover {
  background: var(--accent-deep);
  transform: translateY(-2px);
  box-shadow: 0 12px 26px rgba(200, 128, 79, .28);
}

/* ---------- 作品区 ---------- */
.works {
  padding: clamp(56px, 9vh, 88px) 0 0;
}

.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 34px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--line);
}

.section-head h2 {
  margin: 0;
  font: 400 26px/1 var(--serif);
  letter-spacing: .06em;
}

.section-head span {
  font-size: 12px;
  letter-spacing: .12em;
  color: var(--ink-soft);
}

.work-card {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr);
  gap: 34px;
  padding: 26px 0 42px;
  border-bottom: 1px solid var(--line);
}

.cover {
  position: relative;
  display: block;
  overflow: hidden;
  border-radius: 18px;
  background: var(--paper-deep);
  aspect-ratio: 16 / 9;
  box-shadow: 0 12px 32px rgba(120, 90, 60, .10);
}

button.cover {
  width: 100%;
  padding: 0;
  border: 0;
  font: inherit;
  cursor: pointer;
  appearance: none;
}

.cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .55s ease;
}

.cover:hover img { transform: scale(1.03); }

/* 封面上常显的播放键 */
.play-btn {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 60px;
  height: 60px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding-left: 4px;
  border-radius: 50%;
  background: rgba(255, 252, 247, .95);
  color: var(--accent-deep);
  font-size: 20px;
  box-shadow: 0 10px 28px rgba(120, 90, 60, .22);
  transition: transform .25s ease, background .25s ease;
}

.cover:hover .play-btn {
  transform: translate(-50%, -50%) scale(1.08);
  background: #fff;
}

.play-label {
  position: absolute;
  left: 50%;
  bottom: 16px;
  transform: translateX(-50%);
  padding: 5px 14px;
  border-radius: 999px;
  background: rgba(255, 252, 247, .9);
  color: var(--accent-deep);
  font-size: 12px;
  letter-spacing: .06em;
  white-space: nowrap;
}

.meta { padding: 6px 0; }

.meta-top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 14px;
}

.meta h3 {
  margin: 0;
  font: 400 22px/1.4 var(--serif);
  letter-spacing: .02em;
}

.badge {
  flex: none;
  padding: 3px 11px;
  border-radius: 999px;
  background: var(--sage-soft);
  color: #5e7c68;
  font-size: 11px;
  letter-spacing: .08em;
}

.meta p {
  margin: 0 0 20px;
  font-size: 14.5px;
  color: var(--ink-soft);
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.tags li {
  padding: 4px 12px;
  background: var(--accent-soft);
  border-radius: 999px;
  font-size: 12px;
  color: var(--accent-deep);
  letter-spacing: .04em;
}

/* 占位卡 */
.work-card.placeholder {
  grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr);
}

.cover.empty {
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1.5px dashed #e9dcc9;
  background: rgba(255, 252, 247, .5);
  box-shadow: none;
}

.cover.empty span {
  font: 400 15px/1.8 var(--serif);
  color: #b9a892;
  text-align: center;
  letter-spacing: .08em;
}

.work-card.placeholder h3 { color: var(--ink-soft); }
.work-card.placeholder p { max-width: 26em; }

/* ---------- 关于 ---------- */
.about {
  padding: clamp(56px, 9vh, 92px) 0;
  max-width: 40em;
}

.about h2 {
  margin: 0 0 26px;
  font: 400 26px/1 var(--serif);
  letter-spacing: .06em;
}

.about p {
  margin: 0 0 16px;
  font-size: 15.5px;
}

.about .fine {
  font-size: 13.5px;
  color: var(--ink-soft);
}

/* ---------- 页脚 ---------- */
footer {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  max-width: 1040px;
  margin: 0 auto;
  padding: 24px 28px 44px;
  border-top: 1px solid var(--line);
  font-size: 12px;
  letter-spacing: .08em;
  color: var(--ink-soft);
}

/* ---------- 原地试玩弹窗 ---------- */
.player {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 3vh 3vw;
  background: rgba(74, 58, 46, .52);
  backdrop-filter: blur(6px);
}

.player[hidden] { display: none; }

.player-box {
  display: flex;
  flex-direction: column;
  width: min(1160px, 100%, calc((94vh - 52px) * 16 / 9));
  overflow: hidden;
  border-radius: 20px;
  background: var(--paper);
  box-shadow: 0 30px 80px rgba(60, 40, 25, .38);
}

.player-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 10px 16px 10px 20px;
  border-bottom: 1px solid var(--line);
  background: var(--paper);
}

.player-title {
  font: 400 13px/1 var(--serif);
  letter-spacing: .08em;
  color: var(--ink-soft);
}

.player-close {
  flex: none;
  width: 32px;
  height: 32px;
  border: 0;
  border-radius: 50%;
  background: var(--paper-deep);
  color: var(--ink);
  font-size: 15px;
  cursor: pointer;
  transition: background .2s ease, color .2s ease;
}

.player-close:hover {
  background: var(--accent-soft);
  color: var(--accent-deep);
}

.player iframe {
  flex: none;
  width: 100%;
  aspect-ratio: 16 / 9;
  height: auto;
  border: 0;
  background: #f3e9df;
}

/* ---------- 手机 ---------- */
@media (max-width: 760px) {
  .work-card,
  .work-card.placeholder {
    grid-template-columns: minmax(0, 1fr);
    gap: 20px;
  }

  .meta { min-width: 0; }

  .hero { padding: 56px 0 66px; }
  .hero::after { opacity: .6; }

  .top nav { gap: 18px; }

  footer {
    flex-direction: column;
    gap: 6px;
  }

  .player { padding: 0; }
  .player-box {
    width: 100%;
    height: 100%;
    border-radius: 0;
  }
  .player iframe {
    flex: 1;
    aspect-ratio: auto;
    height: auto;
  }
}

/* Portfolio motion */
@keyframes arrive {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes glow-drift {
  50% { transform: translate(-12px, 7px) scale(1.15); opacity: .9; }
}
@keyframes play-ring {
  from { transform: scale(.9); opacity: .85; }
  to { transform: scale(1.45); opacity: 0; }
}
.cover:focus-visible {
  outline: 3px solid var(--accent-deep);
  outline-offset: 4px;
}
@media (prefers-reduced-motion: no-preference) {
  .hero h1 { animation: arrive .48s ease-out backwards; }
  .hero .lede { animation: arrive .48s .08s ease-out backwards; }
  .hero .cta { animation: arrive .48s .16s ease-out backwards; }
  .hero::after { animation: glow-drift 4s ease-in-out; }
  .cover:is(:hover, :focus-visible) .play-btn::after {
    content: "";
    position: absolute;
    inset: 0;
    border: 2px solid white;
    border-radius: 50%;
    pointer-events: none;
    animation: play-ring .65s ease-out both;
  }
  .player:not([hidden]) .player-box { animation: arrive .22s ease-out; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .cover img, .play-btn, .cta { transition: none; }
  .cover:hover img, .cta:hover { transform: none; }
  .cover:hover .play-btn { transform: translate(-50%, -50%); }
}
