:root {
  --paper: #f7f7f3;
  --white: #ffffff;
  --ink: #171a1d;
  --muted: #62696d;
  --line: #d9ddda;
  --pink: #e8b8c6;
  --pink-soft: #f6e9ed;
  --teal: #2a8c82;
  --teal-soft: #e6f1ef;
  --content: min(1180px, calc(100vw - 48px));
  --serif: "STSong", "Songti SC", "Noto Serif CJK SC", serif;
  --sans: "Microsoft YaHei", "PingFang SC", "Noto Sans CJK SC", sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--ink); background: var(--paper); font-family: var(--sans); line-height: 1.65; letter-spacing: 0; }
body.nav-open { overflow: hidden; }
a { color: inherit; text-decoration: none; }
button, a { -webkit-tap-highlight-color: transparent; }
button { font: inherit; }
.skip-link { position: fixed; left: 16px; top: -80px; z-index: 100; background: var(--ink); color: white; padding: 10px 14px; }
.skip-link:focus { top: 16px; }
:focus-visible { outline: 3px solid var(--teal); outline-offset: 4px; }

.site-header { position: fixed; z-index: 40; left: 0; top: 0; width: 100%; height: 82px; padding: 0 max(24px, calc((100vw - 1320px) / 2)); display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid transparent; transition: background .25s ease, border-color .25s ease; }
.site-header.scrolled { background: rgba(247,247,243,.94); border-color: var(--line); backdrop-filter: blur(12px); }
.brand { display: inline-flex; align-items: center; gap: 12px; min-width: 142px; }
.brand > span:last-child { display: grid; line-height: 1; gap: 5px; }
.brand strong { font-family: var(--serif); font-size: 22px; }
.brand small { color: var(--muted); font-size: 8px; letter-spacing: .16em; }
.brand-mark { position: relative; width: 34px; height: 34px; display: block; }
.brand-mark i { position: absolute; width: 10px; height: 16px; left: 12px; top: 1px; border: 1px solid var(--teal); border-radius: 70% 20% 70% 30%; transform-origin: 5px 16px; background: rgba(255,255,255,.4); }
.brand-mark i:nth-child(2) { transform: rotate(72deg); }
.brand-mark i:nth-child(3) { transform: rotate(144deg); }
.brand-mark i:nth-child(4) { transform: rotate(216deg); }
.brand-mark i:nth-child(5) { transform: rotate(288deg); }
.brand-mark::after { content: ""; position: absolute; width: 6px; height: 6px; left: 14px; top: 14px; background: var(--pink); border-radius: 50%; }
.site-nav { display: flex; align-items: center; gap: 30px; font-size: 13px; }
.site-nav a { position: relative; padding: 8px 0; }
.site-nav a::after { content: ""; position: absolute; left: 0; bottom: 3px; width: 100%; height: 1px; background: var(--teal); transform: scaleX(0); transform-origin: right; transition: transform .2s ease; }
.site-nav a:hover::after { transform: scaleX(1); transform-origin: left; }
.site-nav .nav-utility { padding: 8px 12px; border: 1px solid var(--line); }
.site-nav .nav-utility::after { display: none; }
.nav-toggle { display: none; width: 42px; height: 42px; border: 0; background: transparent; position: relative; }
.nav-toggle span { position: absolute; left: 10px; width: 22px; height: 1px; background: var(--ink); transition: transform .2s ease, top .2s ease; }
.nav-toggle span:first-child { top: 16px; }
.nav-toggle span:last-child { top: 25px; }

.hero { min-height: min(900px, 96vh); position: relative; overflow: hidden; display: grid; align-items: center; padding: 112px max(24px, calc((100vw - 1320px) / 2)) 70px; border-bottom: 1px solid var(--line); }
.hero-media { position: absolute; inset: 0; background: linear-gradient(90deg, rgba(247,247,243,.98) 0%, rgba(247,247,243,.9) 35%, rgba(247,247,243,.12) 65%), url('/assets/hero.webp') center/cover no-repeat; }
.hero-content { position: relative; z-index: 2; width: min(660px, 58vw); }
.eyebrow { margin: 0 0 18px; color: var(--teal); font-size: 11px; font-weight: 700; letter-spacing: .14em; }
.hero h1 { margin: 0; font-family: var(--serif); font-size: clamp(58px, 7.2vw, 108px); font-weight: 700; line-height: 1.03; }
.hero-lead { margin: 24px 0 0; max-width: 620px; font-family: var(--serif); font-size: clamp(24px, 3vw, 38px); line-height: 1.35; }
.hero-copy { margin: 20px 0 0; color: var(--muted); max-width: 560px; font-size: 15px; }
.hero-actions, .contact-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 34px; }
.button { min-height: 46px; padding: 11px 18px; border: 1px solid var(--ink); display: inline-flex; align-items: center; justify-content: center; gap: 18px; cursor: pointer; border-radius: 2px; transition: transform .2s ease, background .2s ease, color .2s ease; }
.button:hover { transform: translateY(-2px); }
.button-primary { background: var(--ink); color: white; }
.button-quiet { background: rgba(247,247,243,.65); color: var(--ink); }
.hero-index { position: absolute; z-index: 2; right: max(24px, calc((100vw - 1320px) / 2)); bottom: 46px; display: flex; align-items: end; gap: 12px; color: var(--muted); }
.hero-index span { font-size: 10px; writing-mode: vertical-rl; letter-spacing: .14em; }
.hero-index b { font-size: 48px; line-height: 1; font-weight: 300; }

.value-band { width: var(--content); margin: 0 auto; padding: 72px 0 86px; }
.value-band > p { margin: 0 0 34px; color: var(--muted); font-size: 14px; }
.value-grid { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--ink); }
.value-grid article { padding: 24px 30px 0 0; min-height: 180px; border-right: 1px solid var(--line); }
.value-grid article + article { padding-left: 30px; }
.value-grid article:last-child { border-right: 0; }
.value-grid span, .service-row > span, .work-item > div + div > p, .process-list > li > span, .model-grid span { color: var(--teal); font-size: 10px; font-weight: 700; letter-spacing: .12em; }
.value-grid h2 { margin: 22px 0 8px; font-family: var(--serif); font-size: 25px; }
.value-grid p { margin: 0; color: var(--muted); font-size: 14px; }

.section { padding: 104px max(24px, calc((100vw - 1180px) / 2)); }
.section-heading { max-width: 760px; margin-bottom: 56px; }
.section-heading h2, .contact h2 { margin: 0; font-family: var(--serif); font-size: clamp(36px, 5vw, 66px); line-height: 1.18; }
.section-heading > p:last-child { margin: 20px 0 0; color: var(--muted); }
.services { background: var(--white); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.service-list { border-top: 1px solid var(--ink); }
.service-row { display: grid; grid-template-columns: 80px minmax(210px, 1.2fr) minmax(300px, 2fr) minmax(230px, 1.1fr); align-items: center; gap: 20px; min-height: 128px; border-bottom: 1px solid var(--line); transition: padding .2s ease, background .2s ease; }
.service-row:hover { padding-left: 12px; background: var(--paper); }
.service-row h3 { margin: 0; font-family: var(--serif); font-size: 24px; }
.service-row p { margin: 0; color: var(--muted); font-size: 14px; }
.service-row b { font-size: 11px; font-weight: 500; color: var(--teal); }

.work { background: var(--ink); color: white; }
.work .section-heading > p:last-child { color: #aeb4b5; }
.work-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; background: #3a3e40; border: 1px solid #3a3e40; }
.work-item { background: var(--ink); min-height: 520px; display: grid; grid-template-rows: 230px 1fr; }
.work-item > div:last-child { padding: 34px; }
.work-item h3 { margin: 10px 0 14px; font-family: var(--serif); font-size: 28px; }
.work-item p { color: #c3c8c8; }
.work-item ul { padding: 0; margin: 26px 0 0; display: flex; flex-wrap: wrap; gap: 8px; list-style: none; }
.work-item li { padding: 6px 9px; border: 1px solid #4a5051; color: #dfe3e2; font-size: 11px; }
.work-visual { position: relative; overflow: hidden; background: #202426; border-bottom: 1px solid #3a3e40; }
.visual-knowledge { display: grid; place-items: center; grid-template-columns: repeat(3, 84px); gap: 20px; }
.visual-knowledge span { width: 84px; height: 84px; display: grid; place-items: center; border: 1px solid var(--pink); border-radius: 50%; font-size: 10px; }
.visual-knowledge span:nth-child(2) { background: var(--teal); border-color: var(--teal); }
.visual-knowledge::before, .visual-knowledge::after { content: ""; position: absolute; width: 50px; height: 1px; background: var(--pink); left: calc(50% - 105px); }
.visual-knowledge::after { left: calc(50% + 55px); }
.visual-flow { display: flex; align-items: center; justify-content: center; gap: 38px; }
.visual-flow i { width: 42px; height: 42px; border: 1px solid var(--teal); transform: rotate(45deg); }
.visual-flow i:nth-child(2) { width: 70px; height: 70px; background: rgba(42,140,130,.2); }
.visual-flow::after { content: ""; position: absolute; width: 70%; height: 1px; background: var(--pink); }
.visual-app { display: grid; place-items: center; }
.visual-app > div { width: 116px; height: 190px; border: 2px solid #e7e9e8; border-radius: 20px; padding: 30px 12px 12px; display: grid; gap: 10px; }
.visual-app span { background: #343a3b; border-left: 4px solid var(--teal); }
.visual-site { display: grid; grid-template-columns: 1.5fr 1fr; grid-template-rows: 1fr 1fr; gap: 8px; padding: 38px; }
.visual-site span { border: 1px solid #555d5e; background: #292e30; }
.visual-site span:first-child { grid-row: 1 / 3; border-color: var(--pink); }

.process { background: var(--paper); }
.process-list { list-style: none; padding: 0; margin: 0; border-top: 1px solid var(--ink); }
.process-list li { display: grid; grid-template-columns: 90px 1fr 170px; gap: 24px; align-items: center; min-height: 118px; border-bottom: 1px solid var(--line); }
.process-list h3 { margin: 0 0 5px; font-family: var(--serif); font-size: 23px; }
.process-list p { margin: 0; color: var(--muted); font-size: 14px; }
.process-list b { justify-self: end; color: var(--teal); font-size: 12px; font-weight: 500; }

.model { background: var(--pink-soft); border-top: 1px solid #e4d6da; border-bottom: 1px solid #e4d6da; }
.model-grid { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--ink); }
.model-grid article { padding: 30px 28px 10px 0; min-height: 240px; border-right: 1px solid #d8c9cd; }
.model-grid article + article { padding-left: 28px; }
.model-grid article:last-child { border-right: 0; }
.model-grid h3 { font-family: var(--serif); font-size: 27px; margin: 28px 0 10px; }
.model-grid p { color: var(--muted); }
.model-grid b { display: block; margin-top: 26px; font-size: 12px; color: var(--teal); }

.contact { min-height: 650px; display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(280px, .8fr); gap: 80px; align-items: center; padding: 110px max(24px, calc((100vw - 1180px) / 2)); background: var(--white); }
.contact-copy > p:not(.eyebrow):not(.copy-status) { max-width: 650px; color: var(--muted); }
.contact-note { border-left: 1px solid var(--line); padding: 30px 0 30px 38px; }
.contact-note > span { color: var(--teal); font-size: 11px; font-weight: 700; }
.contact-note p { font-family: var(--serif); font-size: 22px; line-height: 1.5; }
.contact-note a { display: inline-flex; gap: 16px; color: var(--teal); font-size: 13px; border-bottom: 1px solid var(--teal); }
.copy-status { min-height: 24px; color: var(--teal); font-size: 12px; }

.site-footer { min-height: 180px; padding: 42px max(24px, calc((100vw - 1180px) / 2)); display: grid; grid-template-columns: 1fr 1fr 1fr; align-items: center; gap: 30px; background: var(--ink); color: white; }
.footer-brand strong { color: white; }
.site-footer > p { text-align: center; color: #aeb4b5; font-size: 12px; }
.site-footer > div:last-child { display: flex; justify-content: flex-end; gap: 20px; color: #aeb4b5; font-size: 11px; }
.site-footer a { color: var(--pink); }

.reveal { opacity: 0; transform: translateY(22px); transition: opacity .65s ease, transform .65s ease; }
.reveal.visible { opacity: 1; transform: none; }

@media (max-width: 900px) {
  :root { --content: calc(100vw - 32px); }
  .site-header { height: 68px; padding-inline: 16px; }
  .nav-toggle { display: block; z-index: 3; }
  .site-nav { position: fixed; inset: 0; background: var(--paper); padding: 104px 24px 40px; display: flex; flex-direction: column; align-items: flex-start; gap: 18px; transform: translateX(100%); transition: transform .25s ease; font-family: var(--serif); font-size: 30px; }
  .site-nav.open { transform: none; }
  .site-nav .nav-utility { margin-top: auto; font-family: var(--sans); font-size: 13px; }
  .nav-toggle[aria-expanded="true"] span:first-child { top: 21px; transform: rotate(45deg); }
  .nav-toggle[aria-expanded="true"] span:last-child { top: 21px; transform: rotate(-45deg); }
  .hero { min-height: 820px; padding: 100px 20px 54px; align-items: end; }
  .hero-media { background: linear-gradient(0deg, rgba(247,247,243,.98) 0%, rgba(247,247,243,.88) 45%, rgba(247,247,243,.12) 80%), url('/assets/hero.webp') 66% center/cover no-repeat; }
  .hero-content { width: 100%; }
  .hero h1 { font-size: clamp(54px, 17vw, 82px); }
  .hero-lead { font-size: 26px; }
  .hero-index { display: none; }
  .value-band { padding: 56px 0 64px; }
  .value-grid, .model-grid { grid-template-columns: 1fr; }
  .value-grid article, .value-grid article + article, .model-grid article, .model-grid article + article { padding: 24px 0; min-height: 0; border-right: 0; border-bottom: 1px solid var(--line); }
  .section { padding: 78px 18px; }
  .section-heading { margin-bottom: 38px; }
  .service-row { grid-template-columns: 48px 1fr; padding: 24px 0; gap: 8px 14px; }
  .service-row p, .service-row b { grid-column: 2; }
  .service-row:hover { padding-left: 0; }
  .work-grid { grid-template-columns: 1fr; }
  .work-item { min-height: 0; grid-template-rows: 210px auto; }
  .process-list li { grid-template-columns: 52px 1fr; padding: 22px 0; gap: 12px; }
  .process-list b { grid-column: 2; justify-self: start; }
  .contact { grid-template-columns: 1fr; gap: 50px; padding: 82px 18px; }
  .contact-note { padding-left: 24px; }
  .site-footer { grid-template-columns: 1fr; text-align: left; padding: 42px 18px; }
  .site-footer > p { text-align: left; }
  .site-footer > div:last-child { justify-content: flex-start; flex-wrap: wrap; }
}

@media (max-width: 520px) {
  .hero { min-height: 760px; }
  .hero-copy { font-size: 14px; }
  .hero-actions, .contact-actions { align-items: stretch; flex-direction: column; }
  .button { width: 100%; justify-content: space-between; }
  .work-item > div:last-child { padding: 26px 20px; }
  .visual-knowledge { grid-template-columns: repeat(3, 64px); gap: 12px; }
  .visual-knowledge span { width: 64px; height: 64px; }
  .visual-knowledge::before { left: calc(50% - 77px); width: 30px; }
  .visual-knowledge::after { left: calc(50% + 47px); width: 30px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
  .reveal { opacity: 1; transform: none; }
}
