:root {
  --bg: #f6f8fa;
  --ink: #151a1e;
  --muted: #5d6872;
  --soft: #e9eef3;
  --line: #dde3ea;
  --panel: #ffffff;
  --dark: #101820;
  --dark-2: #152331;
  --blue: #2563eb;
  --green: #16a085;
  --gold: #d6a93a;
  --shadow: 0 22px 60px rgba(16, 24, 32, 0.12);
  --dark-shadow: 0 26px 80px rgba(0, 0, 0, 0.34);
  --max-width: 1180px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--bg);
  font-family: "Microsoft YaHei", "PingFang SC", "Noto Sans CJK SC", Arial, sans-serif;
  line-height: 1.62;
  overflow-x: hidden;
}

body,
main,
section,
header,
footer {
  max-width: 100vw;
}

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

img {
  max-width: 100%;
}

.section-shell {
  width: min(var(--max-width), calc(100% - 44px));
  margin: 0 auto;
  min-width: 0;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  border-bottom: 1px solid rgba(221, 227, 234, 0.72);
  background: rgba(246, 248, 250, 0.82);
  backdrop-filter: blur(18px);
}

.nav {
  width: min(var(--max-width), calc(100% - 44px));
  min-height: 70px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand,
.nav-links {
  display: flex;
  align-items: center;
}

.brand {
  gap: 10px;
  font-weight: 800;
  white-space: nowrap;
}

.brand-mark {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  display: inline-grid;
  place-items: center;
  color: #fff;
  background: linear-gradient(135deg, var(--blue), var(--green));
  font-size: 0.88rem;
}

.nav-links {
  gap: 6px;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.nav-links a {
  min-height: 38px;
  padding: 8px 12px;
  border-radius: 8px;
  color: var(--muted);
  font-size: 0.94rem;
  font-weight: 700;
}

.nav-links a:hover,
.nav-links a.is-active {
  color: var(--ink);
  background: var(--soft);
}

.hero {
  position: relative;
  min-height: min(760px, calc(100vh - 120px));
  padding: 54px 0 62px;
  display: grid;
  align-items: center;
  overflow: hidden;
  color: #f8fbff;
  background:
    radial-gradient(circle at 78% 24%, rgba(37, 99, 235, 0.28), transparent 28%),
    radial-gradient(circle at 52% 85%, rgba(22, 160, 133, 0.18), transparent 26%),
    linear-gradient(135deg, #101820 0%, #132030 56%, #0c1117 100%);
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px);
  background-size: 42px 42px;
  mask-image: linear-gradient(90deg, #000 0%, rgba(0, 0, 0, 0.72) 48%, transparent 100%);
  pointer-events: none;
}

.hero-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(420px, 1.08fr);
  align-items: center;
  gap: 52px;
}

.hero-copy {
  min-width: 0;
  max-width: 100%;
}

.eyebrow,
.section-kicker,
.project-type {
  margin: 0 0 12px;
  color: var(--gold);
  font-size: 0.82rem;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.hero h1,
.section-heading h2,
.resume-content h2,
.contact-layout h2,
.featured-copy h3,
.case-card h3 {
  margin: 0;
  line-height: 1.12;
  letter-spacing: 0;
}

.hero h1 {
  max-width: 760px;
  font-size: clamp(2.42rem, 5vw, 4.95rem);
  overflow-wrap: anywhere;
  word-break: break-all;
}

.hero h1 span {
  display: block;
}

.hero-intro,
.hero-proof {
  max-width: 690px;
  margin: 22px 0 0;
  color: rgba(248, 251, 255, 0.78);
  font-size: clamp(1rem, 1.8vw, 1.15rem);
}

.hero-proof {
  position: relative;
  margin-top: 20px;
  padding-left: 18px;
  color: rgba(248, 251, 255, 0.88);
}

.hero-proof::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.38em;
  width: 4px;
  height: calc(100% - 0.76em);
  border-radius: 8px;
  background: var(--green);
}

.hero-actions {
  margin-top: 32px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.button {
  min-height: 46px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 17px;
  border: 1px solid transparent;
  border-radius: 8px;
  font-weight: 900;
  line-height: 1.2;
  transition: transform 180ms ease, background-color 180ms ease, border-color 180ms ease, color 180ms ease;
}

.button:hover {
  transform: translateY(-1px);
}

.button.primary {
  color: #fff;
  background: var(--blue);
  box-shadow: 0 12px 32px rgba(37, 99, 235, 0.24);
}

.button.primary:hover {
  background: #1e55cd;
}

.button.secondary {
  border-color: var(--line);
  color: var(--ink);
  background: #fff;
}

.button.secondary:hover {
  border-color: var(--blue);
  color: var(--blue);
}

.button.ghost {
  border-color: rgba(255, 255, 255, 0.18);
  color: rgba(255, 255, 255, 0.92);
  background: rgba(255, 255, 255, 0.08);
}

.button.ghost:hover {
  border-color: rgba(255, 255, 255, 0.36);
  background: rgba(255, 255, 255, 0.13);
}

.workbench {
  position: relative;
  min-height: 560px;
  padding: 18px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.11), rgba(255, 255, 255, 0.035)),
    rgba(16, 24, 32, 0.72);
  box-shadow: var(--dark-shadow);
  overflow: hidden;
}

.workbench::before,
.workbench::after {
  content: "";
  position: absolute;
  pointer-events: none;
}

.workbench::before {
  inset: 66px 34px 70px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  background:
    linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 24px 24px;
}

.workbench::after {
  right: 42px;
  bottom: 44px;
  width: 48%;
  height: 2px;
  background: linear-gradient(90deg, transparent, rgba(22, 160, 133, 0.8), rgba(214, 169, 58, 0.74), transparent);
}

.workbench-topline {
  position: relative;
  z-index: 2;
  min-height: 36px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.8rem;
  font-weight: 900;
  text-transform: uppercase;
}

.workbench-canvas {
  position: relative;
  height: 492px;
}

.screen-tile {
  position: absolute;
  margin: 0;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 8px;
  background: #0f1720;
  box-shadow: 0 22px 44px rgba(0, 0, 0, 0.33);
  overflow: hidden;
}

.screen-tile img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: left top;
  opacity: 0.9;
}

.screen-tile figcaption {
  position: absolute;
  left: 10px;
  bottom: 10px;
  padding: 6px 9px;
  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 6px;
  color: rgba(255, 255, 255, 0.86);
  background: rgba(16, 24, 32, 0.72);
  font-size: 0.76rem;
  font-weight: 900;
  backdrop-filter: blur(12px);
}

.tile-dify {
  z-index: 4;
  width: 62%;
  height: 45%;
  right: 3%;
  top: 7%;
}

.tile-agent {
  z-index: 5;
  width: 44%;
  height: 38%;
  left: 4%;
  top: 30%;
}

.tile-service {
  z-index: 3;
  width: 43%;
  height: 44%;
  right: 12%;
  bottom: 5%;
}

.tile-knowledge {
  z-index: 2;
  width: 34%;
  height: 32%;
  left: 18%;
  bottom: 3%;
}

.status-strip {
  border-bottom: 1px solid var(--line);
  background: #fff;
}

.status-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 1px;
  background: var(--line);
}

.status-grid div {
  min-height: 104px;
  padding: 20px;
  display: grid;
  align-content: center;
  gap: 6px;
  background: #fff;
}

.status-grid span {
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 800;
}

.status-grid strong {
  color: var(--dark);
  font-size: clamp(1.38rem, 2.5vw, 2rem);
  line-height: 1.08;
}

.content-section {
  padding: 84px 0;
}

.section-heading {
  max-width: 820px;
  margin-bottom: 32px;
}

.section-heading h2,
.resume-content h2,
.contact-layout h2 {
  font-size: clamp(1.8rem, 3.8vw, 3rem);
}

.section-heading p:not(.section-kicker),
.resume-content p,
.contact-layout p {
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 1.02rem;
}

.featured-case {
  border: 1px solid var(--line);
  border-radius: 8px;
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(0, 1.08fr);
  overflow: hidden;
  background: #fff;
  box-shadow: var(--shadow);
}

.featured-copy {
  min-width: 0;
  padding: 34px;
  display: grid;
  align-content: start;
  gap: 14px;
}

.featured-copy h3 {
  font-size: clamp(1.7rem, 3vw, 2.55rem);
}

.featured-copy > p:not(.project-type),
.case-card-body > p:not(.project-type) {
  margin: 0;
  color: var(--muted);
  overflow-wrap: anywhere;
}

.proof-list {
  margin: 2px 0 0;
  padding-left: 1.15rem;
}

.proof-list li {
  margin: 7px 0;
}

.metric-strip {
  margin-top: 4px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.metric-strip span {
  min-height: 30px;
  padding: 6px 10px;
  border: 1px solid rgba(22, 160, 133, 0.25);
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  color: #0f6e5d;
  background: rgba(22, 160, 133, 0.08);
  font-size: 0.84rem;
  font-weight: 900;
}

.project-links {
  margin-top: 8px;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.project-links .button {
  min-height: 40px;
  padding: 9px 12px;
  font-size: 0.92rem;
}

.featured-media {
  min-height: 100%;
  margin: 0;
  border-left: 1px solid var(--line);
  background: var(--dark);
  overflow: hidden;
}

.featured-media img {
  width: 100%;
  height: 100%;
  min-height: 520px;
  display: block;
  object-fit: cover;
  object-position: left top;
}

.case-matrix {
  margin-top: 18px;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.case-card {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: #fff;
}

.case-card figure {
  height: 218px;
  margin: 0;
  border-bottom: 1px solid var(--line);
  background: var(--soft);
  overflow: hidden;
}

.case-card img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  object-position: left top;
}

.case-card-body {
  min-width: 0;
  padding: 22px;
  display: flex;
  flex: 1;
  flex-direction: column;
  gap: 12px;
}

.case-card h3 {
  font-size: 1.35rem;
}

.project-links.compact {
  margin-top: auto;
  padding-top: 10px;
}

.project-links.compact a {
  min-height: 36px;
  padding: 7px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  display: inline-flex;
  align-items: center;
  color: var(--blue);
  background: #fff;
  font-size: 0.9rem;
  font-weight: 900;
}

.project-links.compact a:hover {
  border-color: var(--blue);
}

.capability-section {
  padding-top: 20px;
}

.skill-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.skill-grid span {
  min-height: 58px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--dark);
  background: #fff;
  font-weight: 900;
  text-align: center;
}

.resume-band,
.contact-section {
  border-top: 1px solid var(--line);
  background: #fff;
}

.resume-content,
.contact-layout {
  padding: 58px 0;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 32px;
}

.resume-content p,
.contact-layout p {
  max-width: 720px;
}

.resume-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 12px;
}

.contact-links {
  display: grid;
  gap: 10px;
  min-width: min(100%, 330px);
}

.contact-links a {
  min-height: 44px;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 8px;
  display: flex;
  align-items: center;
  color: var(--blue);
  background: #fff;
  font-weight: 900;
  overflow-wrap: anywhere;
}

.contact-links a:hover {
  border-color: var(--blue);
}

.site-footer {
  border-top: 1px solid var(--line);
}

.footer-content {
  min-height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  color: var(--muted);
  font-size: 0.95rem;
}

.footer-content p {
  margin: 0;
}

.footer-content a {
  color: var(--blue);
  font-weight: 900;
}

@media (max-width: 980px) {
  .hero {
    min-height: auto;
  }

  .hero-grid,
  .featured-case,
  .resume-content,
  .contact-layout {
    grid-template-columns: 1fr;
  }

  .workbench {
    min-height: 480px;
  }

  .workbench-canvas {
    height: 412px;
  }

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

  .case-matrix,
  .skill-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .featured-media {
    border-left: 0;
    border-top: 1px solid var(--line);
  }

  .featured-media img {
    min-height: 380px;
  }

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

@media (max-width: 700px) {
  html,
  body {
    width: 100%;
    max-width: 100%;
    overflow-x: hidden;
  }

  .section-shell,
  .nav {
    width: calc(100vw - 36px);
    max-width: calc(100vw - 36px);
  }

  .nav {
    min-height: auto;
    padding: 14px 0;
    align-items: flex-start;
    flex-direction: column;
  }

  .nav-links {
    width: 100%;
    justify-content: flex-start;
  }

  .nav-links a {
    padding-inline: 9px;
  }

  .hero {
    padding: 42px 0 52px;
  }

  .hero-grid {
    gap: 34px;
    max-width: calc(100vw - 36px);
    overflow: hidden;
  }

  .hero-copy,
  .hero-intro,
  .hero-proof {
    width: 100%;
    max-width: min(100%, 20.5rem);
  }

  .workbench {
    width: 100%;
    max-width: calc(100vw - 36px);
  }

  .hero h1 {
    max-width: calc(100vw - 36px);
    font-size: clamp(1.9rem, 8.2vw, 2.28rem);
    overflow-wrap: anywhere;
    word-break: break-all;
  }

  .hero-intro,
  .hero-proof {
    font-size: 1rem;
    overflow-wrap: anywhere;
    word-break: break-all;
  }

  .hero-actions,
  .hero-actions .button,
  .resume-actions,
  .resume-actions .button {
    width: 100%;
  }

  .workbench {
    min-height: auto;
    padding: 14px;
    overflow: hidden;
  }

  .workbench-topline {
    align-items: flex-start;
    flex-direction: column;
    gap: 4px;
  }

  .workbench-canvas {
    height: auto;
    display: grid;
    gap: 12px;
  }

  .screen-tile {
    position: relative;
    inset: auto;
    width: 100%;
    height: 188px;
  }

  .tile-dify,
  .tile-agent,
  .tile-service,
  .tile-knowledge {
    width: 100%;
    height: 188px;
    left: auto;
    right: auto;
    top: auto;
    bottom: auto;
  }

  .status-grid,
  .case-matrix,
  .skill-grid {
    grid-template-columns: 1fr;
  }

  .status-grid div {
    min-height: 86px;
  }

  .content-section {
    padding: 62px 0;
  }

  .featured-copy,
  .case-card-body {
    padding: 20px;
  }

  .featured-media img {
    min-height: 300px;
  }

  .case-card figure {
    height: 190px;
  }

  .project-links,
  .project-links .button,
  .project-links.compact a {
    width: 100%;
  }

  .footer-content {
    padding: 18px 0;
    align-items: flex-start;
    flex-direction: column;
  }
}
