:root {
  --bg: #f7f9f8;
  --surface: #ffffff;
  --surface-soft: #edf5f3;
  --ink: #101827;
  --muted: #5d6978;
  --line: #dbe4e1;
  --navy: #06192d;
  --blue: #2388c7;
  --cyan: #37bee8;
  --green: #25ad5e;
  --orange: #ff8a17;
  --violet: #8052b8;
  --coral: #f04d43;
  --shadow: 0 18px 45px rgba(16, 24, 39, 0.08);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.6;
  overflow-x: hidden;
}

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

a {
  color: inherit;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  min-height: 76px;
  padding: 14px 44px;
  background: rgba(247, 249, 248, 0.93);
  border-bottom: 1px solid rgba(219, 228, 225, 0.82);
  backdrop-filter: blur(16px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: var(--navy);
  font-size: 1.2rem;
  font-weight: 760;
  text-decoration: none;
  white-space: nowrap;
}

.brand-mark {
  display: inline-grid;
  width: 38px;
  height: 38px;
  place-items: center;
  border: 2px solid var(--navy);
  border-radius: 8px;
  color: var(--navy);
  background: #ffffff;
  box-shadow: inset 0 -6px 0 rgba(55, 190, 232, 0.18);
}

.site-nav {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
}

.lang-switcher {
  margin-left: 12px;
}

.lang-switcher select {
  min-height: 36px;
  padding: 6px 8px;
  border-radius: 6px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
}

.visually-hidden {
  position: absolute !important;
  height: 1px; width: 1px;
  overflow: hidden;
  clip: rect(1px, 1px, 1px, 1px);
  white-space: nowrap;
}

.nav-link {
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
  gap: 7px;
  min-height: 42px;
  padding: 8px 11px;
  border: 1px solid transparent;
  border-radius: 8px;
  color: var(--muted);
  font-size: 0.94rem;
  font-weight: 650;
  text-decoration: none;
  white-space: nowrap;
}

.nav-link img {
  width: 22px;
  height: 22px;
  flex: 0 0 22px;
}

.nav-link:hover,
.nav-link:focus-visible,
.nav-link.is-active {
  color: var(--ink);
  background: #ffffff;
  border-color: var(--line);
  outline: none;
}

.hero {
  position: relative;
  min-height: calc(68vh - 76px);
  overflow: hidden;
  border-bottom: 1px solid var(--line);
}

.home-hero {
  display: flex;
  align-items: center;
  padding: 72px 44px;
  background:
    linear-gradient(90deg, rgba(247, 249, 248, 0.99) 0%, rgba(247, 249, 248, 0.9) 40%, rgba(247, 249, 248, 0.1) 72%),
    url("resources/kylinlab-hero.jpg") right center / auto 100% no-repeat;
}

.hero-copy {
  width: min(610px, 100%);
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--blue);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  overflow-wrap: anywhere;
}

h1,
h2,
h3 {
  margin: 0;
  color: var(--ink);
  line-height: 1.1;
}

h1 {
  font-size: 4.4rem;
}

h2 {
  font-size: 2.15rem;
}

h3 {
  font-size: 1.15rem;
}

.hero-text {
  max-width: 560px;
  margin: 22px 0 0;
  color: #344152;
  font-size: 1.22rem;
}

.action-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 32px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 11px 18px;
  border: 1px solid transparent;
  border-radius: 8px;
  font-weight: 750;
  text-decoration: none;
}

.button.primary {
  background: var(--navy);
  color: #ffffff;
  box-shadow: 0 14px 26px rgba(6, 25, 45, 0.18);
}

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

.button:hover,
.button:focus-visible,
.text-link[href]:hover,
.text-link[href]:focus-visible {
  transform: translateY(-1px);
  outline: none;
}

.section {
  width: calc(100% - 44px);
  max-width: 1120px;
  margin: 0 auto;
  padding: 72px 0;
}

.section-head {
  max-width: 720px;
  margin-bottom: 28px;
}

.section-head p:not(.eyebrow) {
  color: var(--muted);
  font-size: 1.05rem;
}

.split-head {
  display: flex;
  max-width: none;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
}

.text-link {
  color: var(--blue);
  font-weight: 760;
  text-decoration: none;
}

.muted-link {
  display: inline-block;
  margin-top: 18px;
  color: var(--muted);
}

.intro-strip {
  padding-top: 58px;
}

.answer-grid,
.card-grid,
.service-grid,
.contact-grid {
  display: grid;
  gap: 18px;
}

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

.answer-grid article {
  padding: 22px;
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.answer-grid span {
  color: var(--green);
  font-weight: 850;
}

.answer-grid p,
.feature-card p,
.service-card p,
.demo-card p,
.article-card p,
.cta-band p,
.stacked-copy p {
  color: var(--muted);
}

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

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

.feature-card,
.service-card,
.article-card,
.demo-card,
.contact-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.feature-card,
.service-card {
  padding: 24px;
}

.card-icon {
  width: 46px;
  height: 46px;
  margin-bottom: 18px;
}

.soft-band {
  width: 100%;
  max-width: none;
  padding: 72px max(22px, calc((100% - 1120px) / 2));
  background: var(--surface-soft);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.article-list {
  display: grid;
  gap: 16px;
}

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

.article-card {
  padding: 24px;
}

.article-card h2 {
  font-size: 1.35rem;
}

.article-card h3 {
  font-size: 1.2rem;
}

.meta-row {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 700;
}

.meta-row span {
  color: var(--green);
}

.demo-card {
  overflow: hidden;
}

.demo-preview {
  display: grid;
  min-height: 190px;
  place-items: center;
  border-bottom: 1px solid var(--line);
}

.demo-preview img {
  width: 76px;
  height: 76px;
}

.blue-preview {
  background: #e7f5fb;
}

.green-preview {
  background: #e9f7ee;
}

.orange-preview {
  background: #fff1df;
}

.violet-preview {
  background: #f0ebf8;
}

.demo-body {
  padding: 24px;
}

.tag {
  width: fit-content;
  margin: 0 0 12px;
  padding: 3px 9px;
  border-radius: 999px;
  background: #eef4f5;
  color: var(--navy);
  font-size: 0.78rem;
  font-weight: 800;
}

.tech-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 18px 0 0;
}

.tech-list span {
  padding: 5px 9px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 700;
}

.cta-band {
  display: flex;
  width: calc(100% - 44px);
  max-width: 1120px;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  margin: 12px auto 72px;
  padding: 34px;
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: var(--shadow);
}

.cta-band div {
  max-width: 760px;
}

.page-hero {
  width: calc(100% - 44px);
  max-width: 1120px;
  margin: 0 auto;
  padding: 82px 0 48px;
  border-bottom: 1px solid var(--line);
}

.page-hero h1 {
  max-width: 820px;
  font-size: 3.2rem;
}

.page-hero p:not(.eyebrow) {
  max-width: 720px;
  color: var(--muted);
  font-size: 1.14rem;
}

.two-column {
  display: grid;
  grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
  gap: 54px;
}

.stacked-copy {
  display: grid;
  gap: 18px;
}

.stacked-copy article {
  padding: 24px;
  background: #ffffff;
  border: 1px solid var(--line);
  border-radius: 8px;
}

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

.contact-card {
  display: block;
  padding: 24px;
  text-decoration: none;
}

.contact-card span {
  display: block;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 750;
}

.contact-card strong {
  color: var(--ink);
}

.site-footer {
  padding: 28px 44px;
  color: var(--muted);
  border-top: 1px solid var(--line);
  text-align: center;
}

.site-footer p {
  margin: 0;
}

@media (max-width: 900px) {
  .site-header {
    align-items: flex-start;
    flex-direction: column;
    gap: 12px;
    padding: 14px 22px;
  }

  .site-nav {
    width: 100%;
    justify-content: flex-start;
    flex-wrap: wrap;
    overflow: visible;
  }

  .home-hero {
    min-height: auto;
    padding: 58px 22px 320px;
    background:
      linear-gradient(180deg, rgba(247, 249, 248, 1) 0%, rgba(247, 249, 248, 0.96) 50%, rgba(247, 249, 248, 0.34) 100%),
      url("resources/kylinlab-hero.jpg") center bottom / 760px auto no-repeat;
  }

  h1 {
    font-size: 3.2rem;
  }

  h2 {
    font-size: 1.85rem;
  }

  .section,
  .page-hero,
  .cta-band {
    width: calc(100% - 32px);
    max-width: 720px;
  }

  .split-head,
  .cta-band {
    align-items: flex-start;
    flex-direction: column;
  }

  .answer-grid,
  .card-grid.three,
  .card-grid.two,
  .service-grid,
  .article-list.compact,
  .two-column,
  .contact-grid {
    grid-template-columns: 1fr;
  }

  .soft-band {
    padding-right: 16px;
    padding-left: 16px;
  }
}

@media (max-width: 560px) {
  .brand {
    font-size: 1.08rem;
  }

  .nav-link {
    min-height: 39px;
    padding: 7px 9px;
    font-size: 0.88rem;
  }

  .nav-link img {
    width: 19px;
    height: 19px;
  }

  .home-hero {
    padding-bottom: 245px;
    background-size: 540px auto;
  }

  h1 {
    font-size: 2.55rem;
  }

  h2 {
    font-size: 1.42rem;
  }

  .site-nav {
    display: grid;
    width: calc(100vw - 44px);
    max-width: 346px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .nav-link {
    justify-content: center;
    min-width: 0;
  }

  .page-hero h1 {
    font-size: 2.35rem;
  }

  .section,
  .page-hero,
  .cta-band {
    margin-left: 16px;
    margin-right: 16px;
    max-width: 358px;
  }

  .hero-text,
  .page-hero p:not(.eyebrow) {
    font-size: 1.02rem;
  }

  .feature-card,
  .service-card,
  .article-card,
  .demo-body,
  .contact-card,
  .cta-band {
    padding: 20px;
  }
}
