:root {
  color-scheme: light;
  --paper: #fbf6ee;
  --ink: #1d2521;
  --muted: #6d7068;
  --line: #ddd2c3;
  --soft: #f4eee4;
  --accent: #0f6458;
  --accent-soft: #e3eee8;
  --warm: #a86442;
  --warm-deep: #8f5234;
  --warm-soft: #efe1d6;
  --white: #ffffff;
  --display: Georgia, "Times New Roman", serif;
  --display-cn: "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans CJK SC", sans-serif;
  --body: "Avenir Next", Avenir, "Helvetica Neue", Arial, "PingFang SC", "Microsoft YaHei", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--body);
  overflow-x: hidden;
}

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

picture {
  display: block;
}

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

button,
textarea {
  font: inherit;
}

button {
  cursor: pointer;
}

.site-header {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 28px;
  max-width: 1400px;
  margin: 0 auto;
  padding: 28px 36px 18px;
  border-bottom: 1px solid var(--line);
  font-family: inherit;
}

.wordmark {
  font-size: 18px;
  font-weight: 800;
  letter-spacing: 0;
}

.site-header nav,
.header-actions,
.intro-links,
.contact-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 14px;
}

.site-header nav {
  justify-content: center;
}

.site-header nav a,
.language,
.admin-header button {
  border: 0;
  background: transparent;
  color: var(--muted);
  font-family: inherit;
  font-size: 15px;
  font-weight: 700;
}

.site-header nav a {
  display: inline-flex;
  min-height: 36px;
  align-items: center;
  border: 1px solid var(--line);
  padding: 0 14px;
  background: rgba(255, 255, 255, 0.32);
  color: var(--ink);
  transition: border-color 160ms ease, background-color 160ms ease, color 160ms ease, transform 160ms ease;
}

.intro-links a {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  border: 1px solid var(--warm);
  padding: 0 18px;
  background: var(--warm);
  color: var(--paper);
  font-family: inherit;
  font-size: 15px;
  font-weight: 800;
  transition: border-color 160ms ease, background-color 160ms ease, color 160ms ease, transform 160ms ease;
}

.site-header nav a:hover,
.language.active,
.intro-links a:hover,
.contact a:hover {
  color: var(--warm);
}

.site-header nav a:hover {
  border-color: var(--warm);
  background: var(--warm-soft);
  color: var(--warm-deep);
  transform: translateY(-1px);
}

.intro-links a:hover {
  border-color: var(--warm-deep);
  background: var(--warm-soft);
  color: var(--warm-deep);
  transform: translateY(-1px);
}

.language.active {
  border-bottom: 1px solid var(--warm);
}

main {
  max-width: 1400px;
  margin: 0 auto;
  padding: 0 36px 44px;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 380px;
  gap: 92px;
  align-items: end;
  padding: 84px 0 74px;
}

.kicker,
.section-title p,
.meta {
  margin: 0 0 14px;
  color: var(--accent);
  font-family: inherit;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 880px;
  margin-bottom: 24px;
  font-size: clamp(50px, 7.4vw, 92px);
  font-weight: 700;
  line-height: 1;
  letter-spacing: 0;
  font-family: var(--display);
}

html[lang="zh-CN"] h1,
html[lang="zh-CN"] .statement p,
html[lang="zh-CN"] .section-title h2,
html[lang="zh-CN"] .chapter-copy h3,
html[lang="zh-CN"] .service-list h3,
html[lang="zh-CN"] .admin-header h2 {
  font-family: var(--display-cn);
  font-weight: 800;
  line-height: 1.12;
}

.lede {
  max-width: 700px;
  margin-bottom: 26px;
  color: #3f4742;
  font-size: 25px;
  line-height: 1.38;
  overflow-wrap: anywhere;
}

.contact a:not(.contact-button) {
  display: inline-flex;
  min-height: 40px;
  align-items: center;
  border-bottom: 1px solid currentColor;
  color: var(--ink);
}

.portrait {
  margin: 0;
}

.portrait img {
  aspect-ratio: 4 / 5;
  border-radius: 2px;
  object-fit: cover;
  object-position: center top;
}

.portrait figcaption {
  margin-top: 12px;
  color: var(--muted);
  font-family: inherit;
  font-size: 13px;
  line-height: 1.4;
}

.statement {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  padding: 38px 0;
}

.statement p {
  max-width: 1080px;
  margin: 0;
  font-size: clamp(25px, 3.2vw, 42px);
  font-weight: 500;
  line-height: 1.3;
  font-family: var(--display);
}

.section {
  padding: 70px 0 18px;
}

.section-title {
  display: grid;
  gap: 14px;
  margin-bottom: 34px;
}

.section-title h2 {
  max-width: 900px;
  margin: 0;
  font-size: clamp(31px, 4vw, 56px);
  font-weight: 700;
  line-height: 1.12;
  font-family: var(--display);
}

.section-title p {
  margin: 0;
  color: var(--accent);
}

.chapter-list {
  border-top: 1px solid var(--line);
}

.work-chapter {
  display: grid;
  grid-template-columns: minmax(300px, 0.74fr) minmax(0, 1.26fr);
  gap: 48px;
  padding: 46px 0;
  border-bottom: 1px solid var(--line);
}

.chapter-copy {
  position: sticky;
  top: 24px;
  align-self: start;
}

.chapter-copy h3 {
  max-width: 560px;
  margin-bottom: 14px;
  font-size: clamp(31px, 3.8vw, 54px);
  font-weight: 700;
  line-height: 1.1;
  font-family: var(--display);
}

.chapter-copy p:not(.meta),
.work-item p:not(.meta) {
  max-width: 620px;
  color: #454b46;
  font-size: 18px;
  line-height: 1.55;
}

.link-note {
  max-width: 520px;
  margin: 18px 0 8px;
  color: var(--muted) !important;
  font-size: 13px !important;
  font-weight: 700;
  line-height: 1.45 !important;
}

.sample-grid,
.visual-gallery,
.image-showcase {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.image-showcase {
  align-items: start;
}

.sample-card {
  margin: 0;
}

.social-board,
.edm-board {
  margin: 0;
}

.social-board-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  background: var(--soft);
  padding: 18px;
}

.social-board-grid img {
  height: 360px;
  background: var(--soft);
  object-fit: contain;
}

.edm-board-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px;
  background: var(--soft);
  padding: 26px;
}

.article-proof-board {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px;
  background: var(--soft);
  padding: 26px;
}

.article-proof-card {
  display: grid;
  gap: 12px;
  align-content: start;
  color: inherit;
}

.article-proof-card picture {
  background: var(--white);
}

.article-proof-card img {
  height: 320px;
  background: var(--white);
  object-fit: cover;
  object-position: center top;
}

.article-proof-card span {
  display: grid;
  gap: 5px;
}

.article-proof-card strong {
  color: var(--ink);
  font-size: 18px;
  font-weight: 800;
  line-height: 1.18;
}

.article-proof-card small {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.35;
}

.script-proof-card {
  grid-column: 1 / -1;
  min-height: 150px;
  align-content: end;
  border-top: 1px solid var(--line);
  padding-top: 22px;
}

.script-proof-card strong {
  font-family: var(--display);
  font-size: clamp(28px, 3vw, 42px);
  font-weight: 700;
}

.script-proof-card small {
  max-width: 720px;
  color: #454b46;
  font-size: 17px;
  font-weight: 500;
  line-height: 1.5;
}

.edm-preview {
  position: relative;
  display: grid;
  gap: 12px;
  color: inherit;
  cursor: pointer;
}

.edm-preview:focus-visible {
  outline: 2px solid var(--warm);
  outline-offset: 4px;
}

.edm-preview > img,
.edm-preview > picture img {
  height: 420px;
  background: var(--soft);
  object-fit: cover;
  object-position: center top;
}

.edm-preview-wide {
  grid-column: 1 / -1;
}

.edm-preview-wide > img,
.edm-preview-wide > picture img {
  height: 340px;
  object-fit: cover;
  object-position: center center;
}

.edm-preview-label {
  display: inline-flex;
  width: fit-content;
  min-height: 36px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--warm);
  padding: 0 14px;
  background: rgba(255, 255, 255, 0.32);
  color: var(--warm-deep);
  box-shadow: none;
  font-size: 12px;
  font-weight: 800;
  transition: border-color 160ms ease, background-color 160ms ease, color 160ms ease, transform 160ms ease;
}

.edm-preview:hover .edm-preview-label,
.edm-preview:focus .edm-preview-label {
  border-color: var(--warm-deep);
  background: var(--warm-soft);
  transform: translateY(-1px);
}

.sample-card.wide,
.sample-card.large,
.image-showcase .wide,
.image-showcase .large {
  grid-column: 1 / -1;
}

.sample-card img {
  height: 260px;
  background: var(--soft);
  object-fit: contain;
}

.image-showcase .sample-card img {
  background: rgba(255, 255, 255, 0.66);
}

.sample-card.wide img,
.sample-card.large img,
.featured-edm img {
  height: 340px;
}

.three-up {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.three-up .sample-card img {
  height: 360px;
}

.three-up .sample-card.tall img {
  aspect-ratio: 4 / 5;
  height: auto;
}

.pr-mosaic .sample-card img {
  height: 250px;
}

.pr-mosaic .wide img {
  height: 300px;
}

.pr-board {
  grid-template-columns: 1fr;
}

.stitched-board img {
  height: auto;
  background: var(--soft);
}

.edm-mosaic {
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
}

.edm-mosaic .scroll-preview img {
  height: 520px;
  object-fit: contain;
  object-position: center top;
}

.edm-mosaic .wide img {
  height: 300px;
}

.event-gallery .large img {
  height: 420px;
}

.event-gallery .sample-card:not(.large) img {
  height: 260px;
}

.event-gallery {
  background: var(--soft);
  padding: 26px;
}

.event-gallery .sample-card img {
  background: var(--soft);
}

.social-samples .sample-card:first-child img,
.event-samples .sample-card:first-child img {
  background: #fff;
}

.sample-card figcaption,
.social-board figcaption,
.edm-board figcaption {
  margin-top: 10px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.35;
}

.evidence-panel {
  display: grid;
  gap: 20px;
}

.edm-links {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
}

.edm-links.compact {
  grid-template-columns: 1fr;
  max-width: 560px;
}

.edm-links a {
  display: grid;
  min-height: 132px;
  align-content: space-between;
  gap: 16px;
  padding: 18px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.36);
  transition: border-color 160ms ease, background-color 160ms ease, transform 160ms ease;
}

.edm-links a:hover {
  border-color: var(--warm);
  background: var(--warm-soft);
  transform: translateY(-1px);
}

.edm-links span {
  color: var(--ink);
  font-size: 18px;
  font-weight: 800;
  line-height: 1.18;
}

.edm-links small {
  color: var(--warm);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.25;
  text-transform: uppercase;
}

.visual-gallery .sample-card:nth-child(2) img,
.visual-gallery .sample-card:nth-child(3) img {
  height: 230px;
}

.work-item a,
.work-links a {
  display: inline-block;
  margin-top: 2px;
  border-bottom: 1px solid currentColor;
  color: var(--warm);
  font-family: inherit;
  font-size: 13px;
  font-weight: 800;
  transition: color 160ms ease, border-color 160ms ease;
}

.work-item a:hover,
.work-links a:hover {
  color: var(--warm-deep);
}

.work-links {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.private-note {
  display: inline-block;
  margin-top: 6px;
  color: var(--muted);
  font-family: inherit;
  font-size: 13px;
  font-style: italic;
  line-height: 1.45;
}

.service-list {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border-top: 1px solid var(--line);
  border-left: 1px solid var(--line);
}

.service-list div {
  min-height: 260px;
  padding: 24px;
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.service-list span {
  color: var(--warm);
  font-family: inherit;
  font-size: 12px;
  font-weight: 900;
}

.service-list h3 {
  margin: 42px 0 12px;
  font-size: 25px;
  font-weight: 700;
  line-height: 1.1;
  font-family: var(--display);
}

.service-list p,
.resume-grid p,
.resume-grid li,
.contact p {
  color: #454b46;
  font-size: 18px;
  line-height: 1.55;
}

.resume-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 44px;
  padding-top: 28px;
  border-top: 1px solid var(--line);
}

.resume-grid ul {
  display: grid;
  gap: 12px;
  margin: 0;
  padding-left: 18px;
}

.contact {
  display: grid;
  align-items: start;
  justify-content: start;
  gap: 24px;
  margin-top: 62px;
  padding: 30px 0 0;
}

.contact p {
  max-width: 520px;
  margin: 0;
}

.contact-actions {
  position: relative;
  justify-content: flex-start;
}

.contact-button {
  display: inline-flex;
  min-height: 44px;
  min-width: 118px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--warm);
  padding: 0 18px;
  background: rgba(255, 255, 255, 0.28);
  color: var(--warm-deep);
  font-size: 15px;
  font-weight: 800;
  transition: border-color 160ms ease, background-color 160ms ease, color 160ms ease, transform 160ms ease, box-shadow 160ms ease;
}

.contact-button:hover,
.contact-button:focus-visible {
  border-color: var(--warm-deep);
  background: var(--warm-soft);
  color: var(--warm-deep);
  box-shadow: 0 10px 24px rgba(168, 100, 66, 0.12);
  transform: translateY(-1px);
  outline: none;
}

.contact-qr {
  position: relative;
  display: inline-flex;
}

.qr-popover,
.contact-popover {
  position: absolute;
  left: 0;
  top: calc(100% + 12px);
  z-index: 35;
  pointer-events: none;
  opacity: 0;
  transform: translateY(-4px);
  transition: opacity 160ms ease, transform 160ms ease;
}

.qr-popover {
  display: flex;
  flex-direction: column;
  width: 210px;
  max-width: min(210px, calc(100vw - 36px));
}

.contact-popover {
  width: 220px;
  padding: 12px 14px;
  background: rgba(251, 246, 238, 0.96);
  box-shadow: 0 18px 52px rgba(66, 47, 31, 0.14);
}

.qr-popover img {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid var(--line);
  background: var(--white);
  box-shadow: 0 18px 52px rgba(66, 47, 31, 0.16);
}

.qr-popover span,
.contact-popover span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.35;
  text-align: center;
}

.qr-popover span {
  order: -1;
  margin: 0 0 8px;
}

.mobile-contact-copy {
  display: none !important;
}

.contact-qr:hover .qr-popover,
.contact-qr:focus-within .qr-popover,
.contact-qr:hover .contact-popover,
.contact-qr:focus-within .contact-popover {
  pointer-events: auto;
  opacity: 1;
  transform: translateY(0);
}

.floating-nav {
  position: fixed;
  right: 22px;
  bottom: 22px;
  z-index: 40;
  display: grid;
  gap: 8px;
}

.floating-nav a {
  display: inline-flex;
  min-height: 38px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  padding: 0 14px;
  background: rgba(251, 246, 238, 0.92);
  color: var(--ink);
  box-shadow: 0 10px 28px rgba(66, 47, 31, 0.08);
  font-size: 13px;
  font-weight: 800;
  backdrop-filter: blur(10px);
  transition: border-color 160ms ease, background-color 160ms ease, color 160ms ease, transform 160ms ease;
}

.floating-nav a:last-child {
  border-color: var(--warm);
  background: var(--warm);
  color: var(--paper);
}

.floating-nav a:hover {
  border-color: var(--warm-deep);
  background: var(--warm-soft);
  color: var(--warm-deep);
  transform: translateY(-1px);
}

.admin-panel {
  position: fixed;
  top: 0;
  right: 0;
  z-index: 50;
  width: min(520px, 100vw);
  height: 100vh;
  overflow-y: auto;
  border-left: 1px solid var(--line);
  background: var(--white);
  box-shadow: -20px 0 80px rgba(0, 0, 0, 0.12);
  padding: 22px;
  font-family: inherit;
}

.admin-panel[hidden] {
  display: none;
}

.admin-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 22px;
}

.admin-header p {
  margin-bottom: 6px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
}

.admin-header h2 {
  margin: 0;
  font-size: 34px;
  font-weight: 700;
  font-family: var(--display);
}

.admin-panel label {
  display: grid;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
  font-weight: 800;
}

.admin-panel textarea {
  min-height: 240px;
  border: 1px solid var(--line);
  padding: 12px;
  resize: vertical;
}

.admin-help {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.5;
}

@media (max-width: 900px) {
  .site-header,
  .hero,
  .section-title,
  .work-chapter,
  .work-item,
  .resume-grid,
  .contact {
    grid-template-columns: 1fr;
  }

  .chapter-copy {
    position: static;
  }

  .site-header nav {
    justify-content: flex-start;
  }

  .hero {
    gap: 34px;
    padding-top: 52px;
  }

  .portrait {
    max-width: 360px;
  }

  .service-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .edm-links {
    grid-template-columns: 1fr;
  }

  .three-up {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .contact {
    display: grid;
  }

  .contact-actions {
    justify-content: flex-start;
  }
}

@media (max-width: 620px) {
  .site-header,
  main {
    padding-left: 18px;
    padding-right: 18px;
  }

  main {
    padding-bottom: 92px;
  }

  .site-header {
    gap: 16px;
  }

  .site-header nav,
  .header-actions,
  .intro-links {
    gap: 10px;
  }

  .contact-actions {
    display: grid;
    width: min(100%, 360px);
    gap: 12px;
  }

  .site-header nav a,
  .language,
  .admin-header button,
  .intro-links a,
  .contact-button {
    font-size: 14px;
  }

  h1 {
    font-size: clamp(42px, 13vw, 54px);
  }

  .lede {
    font-size: 21px;
    max-width: 28ch;
    overflow-wrap: normal;
  }

  .statement p {
    font-size: 28px;
  }

  .work-item {
    gap: 18px;
  }

  .sample-grid,
  .visual-gallery,
  .image-showcase,
  .three-up,
  .social-board-grid,
  .article-proof-board,
  .edm-board-grid,
  .edm-mosaic {
    grid-template-columns: 1fr;
  }

  .sample-card img,
  .sample-card.wide img,
  .sample-card.large img,
  .featured-edm img,
  .three-up .sample-card img,
  .three-up .sample-card.tall img,
  .pr-mosaic .sample-card img,
  .pr-mosaic .wide img,
  .edm-mosaic .scroll-preview img,
  .edm-mosaic .wide img,
  .event-gallery .large img,
  .event-gallery .sample-card:not(.large) img,
  .visual-gallery .sample-card:nth-child(2) img,
  .visual-gallery .sample-card:nth-child(3) img,
  .social-board-grid img,
  .article-proof-card img,
  .edm-preview > img,
  .edm-preview-wide > img {
    height: 230px;
  }

  .script-proof-card {
    grid-column: auto;
    min-height: auto;
  }

  .edm-preview-wide {
    grid-column: auto;
  }

  .three-up .sample-card.tall img {
    aspect-ratio: auto;
  }

  .service-list {
    grid-template-columns: 1fr;
  }

  .floating-nav {
    right: auto;
    bottom: 14px;
    left: 18px;
    width: min(270px, calc(100vw - 36px));
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
  }

  .floating-nav a {
    min-height: 42px;
    min-width: 0;
    padding: 0 8px;
    font-size: 10px;
    text-align: center;
    white-space: nowrap;
  }

  .contact-qr {
    display: grid;
    grid-template-columns: 128px minmax(0, 1fr);
    align-items: center;
    gap: 12px;
  }

  .contact-button {
    width: 100%;
    min-width: 0;
  }

  .qr-popover,
  .contact-popover {
    position: static;
    display: none;
    width: 100%;
    max-width: 100%;
    opacity: 1;
    transform: none;
    pointer-events: auto;
  }

  .qr-popover img {
    width: min(100%, 142px);
    margin: 0 auto;
  }

  .contact-popover {
    padding: 0;
    background: transparent;
    box-shadow: none;
  }

  .qr-popover span,
  .contact-popover span {
    font-size: 10px;
    line-height: 1.25;
  }

  .qr-popover span {
    margin-bottom: 5px;
  }

  .desktop-contact-copy {
    display: none !important;
  }

  .mobile-contact-copy {
    display: block !important;
  }

  .contact-qr:hover .qr-popover,
  .contact-qr:focus-within .qr-popover,
  .contact-qr:hover .contact-popover,
  .contact-qr:focus-within .contact-popover {
    display: block;
    transform: none;
  }
}
