:root {
  --bg: #f7f8f6;
  --ink: #17201d;
  --muted: #65726e;
  --line: rgba(23, 32, 29, 0.12);
  --panel: #ffffff;
  --teal: #087d70;
  --teal-dark: #04564e;
  --coral: #ef6547;
  --gold: #d8a23d;
  --graphite: #202725;
  --shadow: 0 18px 50px rgba(23, 32, 29, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

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

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

button,
input,
select,
textarea {
  font: inherit;
}

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 18px clamp(18px, 4vw, 56px);
  color: #fff;
  transition:
    background 0.2s ease,
    box-shadow 0.2s ease,
    color 0.2s ease;
}

.site-header.is-scrolled {
  background: rgba(247, 248, 246, 0.92);
  color: var(--ink);
  box-shadow: 0 10px 28px rgba(23, 32, 29, 0.08);
  backdrop-filter: blur(16px);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 188px;
}

.brand img {
  display: block;
  width: 38px;
  height: 38px;
}

.brand strong,
.brand small {
  display: block;
}

.brand strong {
  font-size: 18px;
  line-height: 1.1;
}

.brand small {
  color: currentColor;
  font-size: 11px;
  font-weight: 700;
  opacity: 0.72;
  text-transform: uppercase;
}

.nav {
  display: flex;
  gap: clamp(16px, 3vw, 32px);
  align-items: center;
  font-size: 14px;
}

.nav a {
  opacity: 0.82;
}

.nav a:hover {
  opacity: 1;
}

.header-action,
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0 20px;
  border: 1px solid transparent;
  border-radius: 8px;
  cursor: pointer;
  font-weight: 700;
  white-space: nowrap;
}

.header-action {
  border-color: currentColor;
  font-size: 14px;
}

.button.primary {
  background: var(--coral);
  color: #fff;
  box-shadow: 0 12px 26px rgba(239, 101, 71, 0.28);
}

.button.ghost {
  border-color: rgba(255, 255, 255, 0.62);
  color: #fff;
}

.hero {
  position: relative;
  min-height: 92vh;
  overflow: hidden;
  color: #fff;
}

.hero-media {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(90deg, rgba(10, 18, 16, 0.88), rgba(10, 18, 16, 0.5) 42%, rgba(10, 18, 16, 0.14)),
    linear-gradient(0deg, rgba(10, 18, 16, 0.35), rgba(10, 18, 16, 0));
}

.hero-content {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  width: min(760px, calc(100% - 36px));
  min-height: 92vh;
  margin-left: clamp(18px, 7vw, 96px);
  padding-top: 88px;
  padding-bottom: 80px;
}

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

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

h1 {
  max-width: 680px;
  margin-bottom: 22px;
  font-size: clamp(42px, 7vw, 82px);
  line-height: 1.02;
  letter-spacing: 0;
}

h2 {
  margin-bottom: 14px;
  font-size: clamp(28px, 4vw, 48px);
  line-height: 1.12;
  letter-spacing: 0;
}

h3 {
  margin-bottom: 10px;
  font-size: 21px;
  line-height: 1.25;
}

.hero-copy {
  max-width: 620px;
  margin-bottom: 30px;
  color: rgba(255, 255, 255, 0.86);
  font-size: clamp(17px, 2vw, 22px);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 38px;
}

.hero-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 140px));
  gap: 14px;
  margin: 0;
}

.hero-stats div {
  padding: 18px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(10px);
}

.hero-stats dt {
  font-size: 28px;
  font-weight: 900;
}

.hero-stats dd {
  margin: 0;
  color: rgba(255, 255, 255, 0.76);
  font-size: 13px;
}

.section {
  width: min(1160px, calc(100% - 36px));
  margin: 0 auto;
  padding: clamp(60px, 8vw, 110px) 0;
}

.section.alt {
  width: 100%;
  padding-right: max(18px, calc((100% - 1160px) / 2));
  padding-left: max(18px, calc((100% - 1160px) / 2));
  background: #edf2ee;
}

.section-heading {
  max-width: 720px;
  margin-bottom: 34px;
}

.section-heading p:not(.eyebrow),
.intro-copy,
.contact-copy p {
  color: var(--muted);
  font-size: 18px;
}

.intro {
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(0, 1fr);
  gap: 52px;
  align-items: start;
}

.intro-copy {
  margin-top: 34px;
}

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

.card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: var(--shadow);
}

.service-card {
  min-height: 268px;
  padding: 24px;
}

.service-card p,
.demo-card p,
.timeline span {
  color: var(--muted);
}

.card-icon {
  display: inline-grid;
  width: 42px;
  height: 42px;
  margin-bottom: 28px;
  place-items: center;
  border-radius: 8px;
  background: rgba(8, 125, 112, 0.1);
  color: var(--teal);
  font-weight: 900;
}

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

.demo-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 16px 34px rgba(23, 32, 29, 0.08);
}

.demo-card > div:last-child {
  padding: 22px;
}

.demo-visual {
  aspect-ratio: 16 / 10;
  position: relative;
  overflow: hidden;
}

.demo-visual span {
  position: absolute;
  border-radius: 8px;
}

.demo-visual.trivia {
  background: linear-gradient(135deg, #0b5f57, #f2c96d);
}

.quiz-panel {
  inset: 16% 14% 42%;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 16px 30px rgba(0, 0, 0, 0.16);
}

.quiz-option {
  width: 34%;
  height: 12%;
  top: 58%;
  background: rgba(255, 255, 255, 0.92);
  animation: quizPulse 3s ease-in-out infinite;
}

.quiz-option.one {
  left: 14%;
}

.quiz-option.two {
  right: 14%;
  animation-delay: 0.45s;
}

.score-chip {
  right: 12%;
  top: 12%;
  display: grid;
  width: 54px;
  height: 34px;
  place-items: center;
  background: var(--coral);
  color: #fff;
  font-weight: 900;
  animation: scorePop 3s ease-in-out infinite;
}

.demo-visual.draw {
  background: linear-gradient(135deg, #293331, #ef6547);
}

.wheel {
  width: 38%;
  aspect-ratio: 1;
  top: 14%;
  left: 31%;
  border-radius: 999px;
  background: conic-gradient(#f8d773 0 25%, #fff 25% 50%, #087d70 50% 75%, #ef6547 75%);
  animation: spinWheel 4s cubic-bezier(0.42, 0, 0.2, 1) infinite;
}

.pointer {
  width: 0;
  height: 0;
  top: 10%;
  left: calc(50% - 9px);
  border-right: 9px solid transparent;
  border-bottom: 24px solid #fff;
  border-left: 9px solid transparent;
  border-radius: 0;
  z-index: 2;
}

.prize-card {
  width: 64%;
  height: 17%;
  bottom: 16%;
  left: 18%;
  background: rgba(255, 255, 255, 0.9);
  animation: prizeSlide 4s ease-in-out infinite;
}

.demo-visual.merge {
  background: linear-gradient(135deg, #087d70, #2a2f2d);
}

.merge-tile {
  width: 23%;
  aspect-ratio: 1;
  box-shadow: 0 14px 24px rgba(0, 0, 0, 0.16);
}

.merge-tile.a {
  top: 18%;
  left: 16%;
  background: #fff;
  animation: tileA 3.8s ease-in-out infinite;
}

.merge-tile.b {
  top: 18%;
  right: 16%;
  background: #fff;
  animation: tileB 3.8s ease-in-out infinite;
}

.merge-tile.c {
  right: 34%;
  bottom: 18%;
  background: var(--gold);
  opacity: 0;
  transform: scale(0.72);
  animation: tileC 3.8s ease-in-out infinite;
}

.merge-spark {
  right: 43%;
  top: 38%;
  width: 22px;
  height: 22px;
  border-radius: 999px;
  background: #fff;
  opacity: 0;
  animation: spark 3.8s ease-in-out infinite;
}

@keyframes quizPulse {
  0%,
  100% {
    transform: translateY(0);
    background: rgba(255, 255, 255, 0.92);
  }
  45% {
    transform: translateY(-4px);
    background: #f8d773;
  }
}

@keyframes scorePop {
  0%,
  50%,
  100% {
    opacity: 0;
    transform: translateY(6px) scale(0.9);
  }
  62%,
  78% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes spinWheel {
  0% {
    transform: rotate(0deg);
  }
  62%,
  100% {
    transform: rotate(745deg);
  }
}

@keyframes prizeSlide {
  0%,
  65% {
    opacity: 0.65;
    transform: translateY(10px);
  }
  80%,
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes tileA {
  0%,
  100% {
    transform: translateX(0);
    opacity: 1;
  }
  45% {
    transform: translateX(42%);
    opacity: 1;
  }
  58%,
  72% {
    transform: translateX(70%);
    opacity: 0;
  }
}

@keyframes tileB {
  0%,
  100% {
    transform: translateX(0);
    opacity: 1;
  }
  45% {
    transform: translateX(-42%);
    opacity: 1;
  }
  58%,
  72% {
    transform: translateX(-70%);
    opacity: 0;
  }
}

@keyframes tileC {
  0%,
  48% {
    opacity: 0;
    transform: scale(0.72);
  }
  62%,
  82% {
    opacity: 1;
    transform: scale(1);
  }
  100% {
    opacity: 0;
    transform: scale(0.86);
  }
}

@keyframes spark {
  0%,
  50%,
  100% {
    opacity: 0;
    transform: scale(0.4);
  }
  58% {
    opacity: 0.95;
    transform: scale(1.8);
  }
}

.split {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
  gap: 60px;
}

.workflow-panel {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 260px;
  gap: 22px;
  align-items: stretch;
}

.timeline {
  display: grid;
  gap: 14px;
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: step;
}

.workflow-aside {
  display: grid;
  align-content: start;
  gap: 16px;
  padding: 22px;
  border-radius: 8px;
  background: var(--graphite);
  color: #fff;
  box-shadow: var(--shadow);
}

.workflow-aside strong {
  display: block;
  margin-bottom: 8px;
  font-size: 18px;
}

.workflow-aside p {
  margin: 0;
  color: rgba(255, 255, 255, 0.74);
}

.timeline li {
  counter-increment: step;
  display: grid;
  grid-template-columns: 48px 1fr;
  gap: 18px;
  align-items: start;
  padding: 18px 0;
  border-bottom: 1px solid var(--line);
}

.timeline li::before {
  content: counter(step, decimal-leading-zero);
  display: grid;
  width: 48px;
  height: 48px;
  place-items: center;
  border-radius: 8px;
  background: var(--graphite);
  color: #fff;
  font-weight: 900;
}

.timeline strong,
.timeline span {
  display: block;
  grid-column: 2;
}

.platform-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.platform-strip span {
  display: inline-flex;
  min-height: 46px;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 0 18px;
  font-weight: 700;
}

.contact {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(320px, 0.7fr);
  gap: 48px;
  align-items: start;
}

.contact-form {
  display: grid;
  gap: 16px;
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow);
}

.contact-form label {
  display: grid;
  gap: 8px;
  color: var(--graphite);
  font-weight: 700;
}

.contact-form input,
.contact-form select,
.contact-form textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px 14px;
  background: #f8faf8;
  color: var(--ink);
  outline: none;
}

.contact-form input:focus,
.contact-form select:focus,
.contact-form textarea:focus {
  border-color: var(--teal);
  box-shadow: 0 0 0 3px rgba(8, 125, 112, 0.12);
}

.contact-list {
  display: grid;
  gap: 8px;
  margin-top: 22px;
  color: var(--graphite);
  font-weight: 800;
}

.footer {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  padding: 28px clamp(18px, 4vw, 56px);
  background: var(--graphite);
  color: rgba(255, 255, 255, 0.78);
}

.footer p {
  margin: 0;
}

.footer a {
  color: rgba(255, 255, 255, 0.78);
}

@media (max-width: 920px) {
  .nav {
    display: none;
  }

  .intro,
  .split,
  .workflow-panel,
  .contact {
    grid-template-columns: 1fr;
    gap: 26px;
  }

  .intro-copy {
    margin-top: 0;
  }

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

@media (max-width: 640px) {
  .site-header {
    padding: 14px 18px;
  }

  .brand {
    min-width: auto;
  }

  .brand img {
    width: 38px;
    height: 38px;
  }

  .brand small {
    display: none;
  }

  .header-action {
    min-height: 40px;
    padding: 0 13px;
  }

  .hero {
    min-height: 90vh;
  }

  .hero-overlay {
    background: linear-gradient(180deg, rgba(10, 18, 16, 0.82), rgba(10, 18, 16, 0.55));
  }

  .hero-content {
    width: calc(100% - 36px);
    min-height: 90vh;
    margin: 0 auto;
    padding-top: 96px;
    padding-bottom: 42px;
  }

  h1 {
    font-size: 40px;
  }

  .hero-actions,
  .hero-stats {
    display: grid;
    grid-template-columns: 1fr;
  }

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

  .section {
    width: min(100% - 28px, 1160px);
  }

  .contact {
    grid-template-columns: 1fr;
  }
}
