:root {
  --bg: #04060f;
  --bg-soft: #0b1122;
  --text: #ebefff;
  --text-soft: #a9b3d8;
  --line: rgba(151, 167, 233, 0.28);
  --line-strong: rgba(176, 193, 255, 0.52);
  --card: rgba(16, 23, 45, 0.7);
  --primary: #7f6bff;
  --primary-2: #3bcff2;
  --success: #4de0a3;
  --danger: #ff7a8d;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
  background: radial-gradient(circle at 12% 8%, rgba(36, 47, 94, 0.72) 0%, transparent 46%),
    radial-gradient(circle at 84% 82%, rgba(20, 51, 72, 0.58) 0%, transparent 42%), var(--bg);
  color: var(--text);
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  overflow-x: hidden;
}

#bg-canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  opacity: 0.55;
  z-index: 0;
}

.cursor-glow {
  position: fixed;
  width: 300px;
  height: 300px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(129, 111, 255, 0.25), transparent 68%);
  filter: blur(14px);
  transform: translate(-50%, -50%);
  pointer-events: none;
  z-index: 1;
}

.scroll-progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 3px;
  width: 0;
  background: linear-gradient(90deg, var(--primary), var(--primary-2), #7af4c2);
  box-shadow: 0 0 14px rgba(116, 100, 255, 0.58);
  z-index: 30;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  padding: 14px min(4.5vw, 58px);
  backdrop-filter: blur(18px);
  background: rgba(5, 8, 17, 0.56);
  border-bottom: 1px solid rgba(157, 173, 232, 0.17);
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 16px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.brand-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: linear-gradient(120deg, var(--primary), var(--primary-2));
  box-shadow: 0 0 20px rgba(116, 101, 255, 0.94);
  animation: pulse 2.3s infinite ease;
}

.brand-text {
  font-family: "Space Grotesk", Inter, sans-serif;
  font-size: 1.03rem;
  font-weight: 700;
  letter-spacing: 0.015em;
}

.topbar nav {
  display: inline-flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 18px;
}

.topbar nav a {
  color: var(--text-soft);
  text-decoration: none;
  font-size: 0.93rem;
  font-weight: 550;
  transition: color 0.22s ease;
}

.topbar nav a:hover {
  color: var(--text);
}

.lang-toggle {
  display: inline-flex;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 4px;
  gap: 3px;
  background: rgba(11, 17, 34, 0.75);
}

.lang-btn {
  border: 0;
  background: transparent;
  color: #c8d1f8;
  border-radius: 999px;
  height: 30px;
  min-width: 70px;
  padding: 0 12px;
  font-size: 0.78rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
}

.lang-btn.active {
  background: linear-gradient(120deg, var(--primary), #4b8bff);
  color: #fff;
}

main {
  position: relative;
  z-index: 2;
}

.section {
  width: min(1120px, 92vw);
  margin: 0 auto;
  padding: 84px 0;
}

.hero {
  padding-top: 110px;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 13px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(118, 104, 255, 0.13);
  color: #dae2ff;
  font-size: 0.84rem;
  font-weight: 650;
}

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

.hero h1 {
  margin-top: 18px;
  font-size: clamp(2.06rem, 5.2vw, 4.38rem);
  line-height: 1.08;
  letter-spacing: -0.03em;
}

.gradient-text {
  background: linear-gradient(95deg, #9d8cff, #37d4de, #95f8c4);
  background-size: 180% 180%;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: gradientShift 7.5s ease infinite;
}

.hero-desc {
  margin-top: 20px;
  max-width: 780px;
  line-height: 1.73;
  color: var(--text-soft);
}

.hero-dynamic {
  margin-top: 22px;
  color: #bec9ff;
  font-weight: 650;
  min-height: 26px;
}

#dynamic-phrase {
  color: #f7f9ff;
  margin-left: 8px;
}

.hero-cta {
  margin-top: 30px;
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 46px;
  border-radius: 12px;
  border: 1px solid transparent;
  text-decoration: none;
  font-weight: 650;
  font-size: 0.95rem;
  padding: 0 22px;
  cursor: pointer;
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease,
    background 0.22s ease;
}

.btn:hover {
  transform: translateY(-2px);
}

.btn-primary {
  color: #fff;
  background: linear-gradient(130deg, var(--primary), #4ea8ff);
  box-shadow: 0 14px 34px rgba(78, 101, 255, 0.34);
}

.btn-primary:hover {
  box-shadow: 0 16px 40px rgba(95, 120, 255, 0.45);
}

.btn-ghost {
  color: #dbe3ff;
  border-color: var(--line);
  background: rgba(16, 24, 47, 0.6);
}

.btn-ghost:hover {
  border-color: var(--line-strong);
  background: rgba(20, 29, 57, 0.82);
}

.metrics {
  margin-top: 34px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.metric-card {
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 18px;
  background: var(--card);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03), 0 14px 36px rgba(5, 8, 22, 0.42);
}

.metric-card h3 {
  font-size: 2rem;
  font-family: "Space Grotesk", Inter, sans-serif;
  margin-bottom: 6px;
}

.metric-card p {
  color: var(--text-soft);
  font-size: 0.92rem;
}

.trust-strip {
  margin-top: 22px;
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.trust-pill {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 8px 12px;
  font-size: 0.82rem;
  color: #d8e1ff;
  background: rgba(10, 16, 34, 0.65);
}

.section-head h2 {
  margin-top: 12px;
  font-size: clamp(1.6rem, 3.5vw, 2.65rem);
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.pain-grid,
.agent-grid,
.usecase-grid,
.assurance-grid {
  margin-top: 26px;
  display: grid;
  gap: 14px;
}

.pain-grid,
.agent-grid,
.usecase-grid,
.assurance-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.pain-card,
.agent-card,
.usecase-card,
.assurance-card,
.loop-steps li,
.faq-item {
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 20px;
  background: var(--card);
  box-shadow: 0 12px 32px rgba(5, 8, 21, 0.42);
  transition: border-color 0.22s ease, background 0.22s ease;
}

.pain-card:hover,
.agent-card:hover,
.usecase-card:hover,
.assurance-card:hover,
.loop-steps li:hover,
.faq-item:hover {
  border-color: rgba(184, 198, 255, 0.47);
  background: rgba(20, 30, 56, 0.84);
}

.pain-card h3,
.agent-card h3,
.usecase-card h3,
.assurance-card h3 {
  font-size: 1.08rem;
  margin-bottom: 10px;
}

.pain-card p,
.usecase-card p,
.assurance-card p {
  color: var(--text-soft);
  line-height: 1.72;
}

.pain-card .solution {
  margin-top: 12px;
  color: #d8f7ff;
}

.agent-card ul {
  margin: 0;
  padding-left: 18px;
  color: var(--text-soft);
  line-height: 1.72;
  display: grid;
  gap: 6px;
}

.agent-card.wide {
  grid-column: span 2;
}

.loop-wrap {
  margin-top: 26px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 22px;
  align-items: center;
}

.loop-orbit {
  position: relative;
  height: 360px;
  border-radius: 50%;
  border: 1px dashed rgba(154, 170, 230, 0.29);
  background: radial-gradient(circle, rgba(118, 104, 255, 0.14), transparent 66%);
  animation: spinSlow 18s linear infinite;
}

.center-node {
  position: absolute;
  inset: 50% auto auto 50%;
  transform: translate(-50%, -50%);
  width: 146px;
  height: 146px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  text-align: center;
  font-family: "Space Grotesk", Inter, sans-serif;
  font-weight: 700;
  background: linear-gradient(130deg, #6755ff, #2bc3e6);
  box-shadow: 0 0 56px rgba(105, 90, 255, 0.48);
}

.orbit-node {
  position: absolute;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 96px;
  height: 40px;
  border-radius: 999px;
  border: 1px solid rgba(169, 183, 247, 0.44);
  background: rgba(10, 17, 35, 0.88);
  font-size: 0.9rem;
  animation: unspin 18s linear infinite;
}

.n1 {
  top: 10%;
  left: 35%;
}

.n2 {
  top: 45%;
  right: -2%;
}

.n3 {
  bottom: 10%;
  left: 38%;
}

.n4 {
  top: 45%;
  left: -4%;
}

.loop-steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 12px;
}

.loop-steps li {
  min-height: 78px;
  display: flex;
  align-items: center;
  padding-left: 56px;
  position: relative;
}

.loop-steps li span {
  position: absolute;
  left: 16px;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: linear-gradient(130deg, var(--primary), #45b6ff);
  font-weight: 700;
  font-size: 0.84rem;
}

.loop-steps li strong {
  font-weight: 600;
  color: #dce5ff;
  line-height: 1.55;
}

.faq-list {
  margin-top: 24px;
  display: grid;
  gap: 12px;
}

.faq-item {
  padding: 0;
  overflow: hidden;
}

.faq-q {
  width: 100%;
  text-align: left;
  border: 0;
  background: transparent;
  color: #ebf0ff;
  font-size: 1rem;
  font-weight: 650;
  padding: 18px 20px;
  cursor: pointer;
}

.faq-a {
  max-height: 0;
  overflow: hidden;
  color: var(--text-soft);
  line-height: 1.68;
  padding: 0 20px;
  transition: max-height 0.28s ease, padding 0.28s ease;
}

.faq-item.open .faq-a {
  padding: 0 20px 18px;
  max-height: 220px;
}

.cta-section {
  border: 1px solid var(--line);
  border-radius: 20px;
  background: linear-gradient(145deg, rgba(19, 29, 57, 0.78), rgba(8, 12, 26, 0.9));
  padding: 56px 24px;
}

.cta-section h2 {
  margin-top: 14px;
  font-size: clamp(1.7rem, 3.7vw, 2.8rem);
  letter-spacing: -0.02em;
}

.cta-section > p {
  margin-top: 12px;
  max-width: 760px;
  color: var(--text-soft);
  line-height: 1.7;
}

.cta-actions {
  margin-top: 22px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

footer {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: 40px 16px 48px;
  color: #8f9bc8;
  font-size: 0.9rem;
}

.reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.75s ease, transform 0.75s ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

.tilt-card {
  transform-style: preserve-3d;
  will-change: transform;
}

@keyframes pulse {
  0%,
  100% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.35);
  }
}

@keyframes gradientShift {
  0%,
  100% {
    background-position: 0% 50%;
  }
  50% {
    background-position: 100% 50%;
  }
}

@keyframes spinSlow {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

@keyframes unspin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(-360deg);
  }
}

@media (max-width: 1050px) {
  .metrics {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .loop-wrap {
    grid-template-columns: 1fr;
  }

  .loop-orbit {
    max-width: 430px;
    width: 100%;
    margin: 0 auto;
  }
}

@media (max-width: 850px) {
  .topbar {
    grid-template-columns: auto 1fr;
    row-gap: 10px;
  }

  .lang-toggle {
    justify-self: end;
  }

  .topbar nav {
    grid-column: 1 / -1;
    justify-content: flex-start;
    gap: 14px;
  }

  .pain-grid,
  .agent-grid,
  .usecase-grid,
  .assurance-grid {
    grid-template-columns: 1fr;
  }

  .agent-card.wide {
    grid-column: span 1;
  }

  .section {
    width: min(1120px, 94vw);
    padding: 70px 0;
  }

  .hero {
    padding-top: 82px;
  }

  .loop-orbit {
    height: 318px;
  }

  .center-node {
    width: 128px;
    height: 128px;
    font-size: 0.95rem;
  }

  .orbit-node {
    min-width: 84px;
    height: 34px;
    font-size: 0.8rem;
  }
}

@media (max-width: 560px) {
  .topbar {
    padding: 12px 14px;
  }

  .lang-btn {
    min-width: 62px;
    font-size: 0.75rem;
  }

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

  .btn {
    width: 100%;
  }

  .hero-cta {
    width: 100%;
  }
}
