:root {
  color-scheme: light;
  --accent: #1598ed;
  --accent-deep: #087bc9;
  --ink: #101820;
  --muted: #586573;
  --grid-line: rgb(229 232 236 / 0.55);
  font-family:
    "SF Pro Display", "SF Pro Text", "PingFang SC", "Microsoft YaHei",
    "Helvetica Neue", Arial, sans-serif;
  font-synthesis: none;
  text-rendering: optimizeLegibility;
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  scroll-behavior: smooth;
}

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  overflow-x: hidden;
  color: var(--ink);
  background-color: #fcfcfe;
  background-image:
    linear-gradient(var(--grid-line) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
  background-position: -1px -1px;
  background-size: 32px 32px;
  font-feature-settings: "cv11", "ss01";
  -webkit-font-smoothing: antialiased;
}

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

button,
a {
  -webkit-tap-highlight-color: transparent;
}

button {
  font: inherit;
}

.site-shell {
  box-sizing: border-box;
  width: min(100%, 1504px);
  min-height: 100svh;
  margin: 0 auto;
  padding-inline: 32px;
}

@media (min-width: 640px) {
  .site-shell {
    padding-top: 8px;
    padding-bottom: 8px;
  }
}

.relay-home {
  position: relative;
  width: 100%;
  min-height: 100svh;
  overflow: hidden;
  color: var(--ink);
  background-color: #fcfcfe;
  background-image:
    linear-gradient(var(--grid-line) 1px, transparent 1px),
    linear-gradient(90deg, var(--grid-line) 1px, transparent 1px);
  background-position: -1px -1px;
  background-size: 32px 32px;
}

.relay-header {
  position: relative;
  z-index: 20;
  display: flex;
  width: min(100%, 1440px);
  height: 68px;
  margin: 0 auto;
  align-items: center;
  gap: 22px;
  padding: 0 28px;
}

.relay-hero {
  position: relative;
  width: min(100%, 1440px);
  min-height: calc(100svh - 68px);
  margin: 0 auto;
}

.hero-copy {
  position: relative;
  z-index: 5;
  width: 53%;
  padding: clamp(120px, 21vh, 200px) 0 80px;
}

.hero-eyebrow {
  display: flex;
  margin-bottom: 22px;
  align-items: center;
  gap: 11px;
  color: #4f5c6a;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 11px;
  letter-spacing: 0.08em;
}

.status-dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 10px var(--accent);
}

.hero-copy h1 {
  max-width: 720px;
  margin: 0;
  font-size: clamp(3.5rem, 6vw, 6.2rem);
  font-weight: 700;
  letter-spacing: -0.055em;
  line-height: 1.03;
  text-wrap: balance;
}

.hero-copy h1 em {
  color: var(--accent-deep);
  font-style: normal;
}

.hero-copy p {
  max-width: 580px;
  margin: 27px 0 0;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.9;
}

.hero-copy p strong {
  color: var(--accent-deep);
}

.hero-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 27px;
}

.hero-button {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 1px solid #d7e0e8;
  border-radius: 5px;
  background: rgb(255 255 255 / 0.92);
  padding: 12px 17px;
  font-size: 13px;
  transition: border-color 0.2s, color 0.2s, background 0.2s, transform 0.2s;
}

.hero-button:hover {
  border-color: var(--accent);
  color: var(--accent-deep);
  transform: translateY(-1px);
}

.hero-button svg,
.hero-chat-options svg,
.hero-chat-head svg,
.hero-chat-reopen svg {
  flex: 0 0 auto;
  fill: none;
  stroke: currentColor;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-width: 2;
}

.hero-button svg,
.hero-chat-reopen svg {
  width: 16px;
  height: 16px;
}

.hero-chat-options svg {
  width: 12px;
  height: 12px;
}

.hero-chat-head svg {
  width: 14px;
  height: 14px;
}

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

.hero-button-dark:hover {
  border-color: var(--accent-deep);
  background: var(--accent-deep);
  color: #fff;
}

.hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 27px;
}

.hero-badges span {
  border-radius: 999px;
  background: rgb(255 255 255 / 0.75);
  padding: 8px 13px;
  color: #536372;
  font-size: 11px;
}

.hero-robot-wrap {
  position: absolute;
  z-index: 6;
  inset: 0 0 0 49%;
  pointer-events: none;
}

.hero-robot-scene {
  position: absolute;
  inset: 3% -8% 4% -13%;
  pointer-events: auto;
}

#canvas3d {
  position: relative;
  z-index: 1;
  display: block;
  width: 100%;
  height: 100%;
  outline: none;
}

.robot-fallback {
  position: absolute;
  z-index: 0;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transform-origin: 50% 52%;
  animation: robot-fallback-idle 4.6s ease-in-out infinite;
  transition: translate 180ms cubic-bezier(0.2, 0.8, 0.2, 1);
}

.robot-fallback[hidden] {
  display: none;
}

@keyframes robot-fallback-idle {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

.hero-robot-status {
  position: absolute;
  z-index: 4;
  color: #596877;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  font-size: 10px;
  letter-spacing: 0.1em;
  line-height: 1.8;
}

.hero-robot-status-left {
  top: 15%;
  left: 1%;
}

.hero-robot-status-right {
  top: 16%;
  right: 1%;
}

.status-muted {
  color: #8998a6;
}

.status-lines {
  margin-top: 8px;
  line-height: 1.65;
}

.status-lines b {
  margin-left: 17px;
  color: #078de1;
  font-weight: 400;
}

.hero-target {
  position: absolute;
  top: 22%;
  right: 19%;
  color: var(--accent);
  font-size: 34px;
  text-shadow: 0 0 14px rgb(21 152 237 / 0.5);
}

.hero-chat {
  position: absolute;
  z-index: 8;
  right: 0;
  bottom: 8%;
  width: 95%;
  border: 1px solid var(--accent);
  background: rgb(255 255 255 / 0.92);
  box-shadow: 0 15px 45px rgb(0 128 220 / 0.2);
  backdrop-filter: blur(12px);
  pointer-events: auto;
}

.hero-chat-head {
  display: flex;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid rgb(21 152 237 / 0.3);
  padding: 11px 15px;
  color: #20303f;
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 10px;
  letter-spacing: 0.14em;
}

.hero-chat-head button {
  display: inline-flex;
  margin-left: auto;
  border: 0;
  background: transparent;
  padding: 0;
  color: #667887;
  cursor: pointer;
}

.transmitting {
  margin-left: auto;
  color: #078de1;
  white-space: nowrap;
}

.hero-chat-body {
  padding: 12px 15px 15px;
}

.hero-chat-message {
  color: #4c5d6d;
  font-size: 12px;
  line-height: 1.7;
}

.cursor-block {
  display: inline-block;
  width: 7px;
  height: 13px;
  margin-left: 3px;
  vertical-align: -2px;
  background: var(--accent);
}

.hero-chat-options {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 7px;
  margin-top: 10px;
}

.hero-chat-options a {
  display: flex;
  align-items: center;
  gap: 7px;
  border: 1px solid #cfe3f3;
  padding: 8px 10px;
  color: #4c5d6d;
  font-size: 11px;
}

.hero-chat-options a:hover {
  border-color: var(--accent);
  color: #078de1;
}

.hero-chat-options .option-arrow {
  margin-left: auto;
}

.hero-chat-reopen {
  position: absolute;
  right: 4%;
  bottom: 8%;
  padding: 12px;
  border: 1px solid var(--accent);
  background: rgb(255 255 255 / 0.92);
  color: #078de1;
  cursor: pointer;
  pointer-events: auto;
}

.hero-chat-reopen svg {
  width: 16px;
  height: 16px;
}

.hero-chat-reopen[hidden] {
  display: none;
}

.anchor-section {
  position: absolute;
  top: 0;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
}

noscript {
  position: fixed;
  z-index: 100;
  right: 16px;
  bottom: 16px;
  max-width: 360px;
  border: 1px solid #d7e0e8;
  background: #fff;
  padding: 12px 16px;
  color: var(--muted);
  font-size: 13px;
  box-shadow: 0 8px 28px rgb(23 43 65 / 0.12);
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

@media (max-width: 1100px) {
  .hero-copy h1 {
    font-size: clamp(3.1rem, 6vw, 5.2rem);
  }

}

@media (max-width: 900px) {
  .site-shell {
    width: 100%;
    padding-inline: 16px;
  }

  .relay-header {
    max-width: none;
  }

  .hero-copy {
    width: 100%;
    padding: 80px 20px 360px;
    text-align: center;
  }

  .hero-copy h1 {
    margin-inline: auto;
  }

.title-second-line {
    display: block;
  }

  .hero-eyebrow,
  .hero-buttons,
  .hero-badges {
    justify-content: center;
  }

  .hero-copy p {
    margin-right: auto;
    margin-left: auto;
  }

  .hero-robot-wrap {
    height: 390px;
    inset: auto 0 0;
  }

  .hero-robot-scene {
    inset: 0 5% -15%;
  }

  .hero-robot-status {
    display: none;
  }

  .hero-target {
    top: 8%;
    right: 17%;
  }

  .hero-chat {
    right: 5%;
    bottom: 2%;
    width: 90%;
  }

  .hero-chat-options {
    display: none;
  }

}

@media (max-width: 560px) {
  .hero-copy {
    padding-right: 17px;
    padding-left: 17px;
  }

  .hero-eyebrow {
    gap: 7px;
    font-size: 9px;
    letter-spacing: 0.04em;
  }

  .hero-copy h1 {
    font-size: clamp(2.55rem, 12vw, 3.5rem);
    letter-spacing: -0.06em;
  }

  .hero-copy p {
    margin-top: 21px;
    font-size: 13px;
    line-height: 1.8;
  }

  .hero-buttons,
  .hero-badges {
    margin-top: 21px;
  }

  .hero-button {
    padding: 10px 13px;
    font-size: 12px;
  }

  .hero-badges span {
    padding: 7px 10px;
    font-size: 10px;
  }

}

@media (min-width: 640px) and (max-width: 900px) {
  .site-shell {
    padding-inline: 24px;
  }
}

@media (max-width: 500px) {
  .hero-copy h1 {
    font-size: clamp(2rem, 8.9vw, 2.6rem);
  }

  .title-second-line {
    white-space: nowrap;
  }
}

@media (max-height: 760px) and (min-width: 901px) {
  .hero-copy {
    padding-top: clamp(85px, 15vh, 120px);
  }

  .hero-copy h1 {
    font-size: clamp(3.2rem, 5.4vw, 5rem);
  }

}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}
