:root {
  --ink: #f6f3ea;
  --muted: #b7c0ba;
  --paper: #101412;
  --panel: rgba(246, 243, 234, 0.08);
  --panel-strong: rgba(246, 243, 234, 0.14);
  --line: rgba(246, 243, 234, 0.16);
  --accent: #7ff0bd;
  --accent-ink: #082116;
  --warm: #f2b778;
  --rose: #f38fa2;
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.42);
  color-scheme: dark;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background:
    radial-gradient(circle at 20% 10%, rgba(127, 240, 189, 0.2), transparent 28rem),
    radial-gradient(circle at 82% 18%, rgba(243, 143, 162, 0.13), transparent 24rem),
    linear-gradient(145deg, #0b0e0d 0%, #111614 48%, #080a09 100%);
  color: var(--ink);
  min-height: 100vh;
  overflow-x: hidden;
}

button,
a {
  font: inherit;
}

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

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

.ambient {
  pointer-events: none;
  position: fixed;
  inset: 0;
  overflow: hidden;
  z-index: -1;
}

.scanline {
  position: absolute;
  inset: 0;
  background-image: linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px);
  background-size: 100% 4px;
  mask-image: linear-gradient(to bottom, transparent, black 18%, black 78%, transparent);
}

.mesh {
  position: absolute;
  width: 46rem;
  aspect-ratio: 1;
  border-radius: 999px;
  filter: blur(80px);
  opacity: 0.18;
  animation: drift 14s ease-in-out infinite alternate;
}

.mesh-a {
  left: -16rem;
  top: 26rem;
  background: var(--accent);
}

.mesh-b {
  right: -18rem;
  top: 6rem;
  background: var(--rose);
  animation-delay: -4s;
}

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem clamp(1rem, 4vw, 4rem);
  background: linear-gradient(to bottom, rgba(8, 10, 9, 0.88), rgba(8, 10, 9, 0));
  backdrop-filter: blur(16px);
}

.brand,
nav {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.brand {
  font-weight: 850;
  letter-spacing: 0;
}

.brand-mark {
  width: 0.85rem;
  height: 0.85rem;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 22px rgba(127, 240, 189, 0.7);
}

nav a,
.nav-action {
  color: var(--muted);
  border: 0;
  background: transparent;
  cursor: pointer;
}

nav a:hover,
.nav-action:hover {
  color: var(--ink);
}

.nav-action {
  color: var(--accent);
}

.hero {
  min-height: 100svh;
  display: grid;
  grid-template-columns: minmax(0, 0.72fr) minmax(24rem, 1.28fr);
  align-items: center;
  gap: clamp(1.5rem, 4vw, 4.5rem);
  padding: 5.25rem clamp(1rem, 5vw, 5rem) 2.25rem;
}

.hero-copy {
  max-width: 42rem;
  animation: rise 800ms ease both;
}

.eyebrow {
  margin: 0 0 1rem;
  color: var(--accent);
  font-size: 0.78rem;
  font-weight: 850;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

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

h1 {
  margin-bottom: 1.25rem;
  font-size: clamp(3.4rem, 7.8vw, 7.4rem);
  line-height: 0.9;
  letter-spacing: 0;
}

h2 {
  font-size: clamp(2rem, 4vw, 4.8rem);
  line-height: 0.96;
  letter-spacing: 0;
}

h3 {
  margin-bottom: 0.55rem;
  font-size: 0.95rem;
}

.hero-text {
  max-width: 35rem;
  color: var(--muted);
  font-size: clamp(1rem, 1.6vw, 1.25rem);
  line-height: 1.6;
}

.hero-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.8rem;
  margin-top: 2rem;
}

.button {
  min-height: 3.1rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 0.85rem 1.15rem;
  border: 1px solid var(--line);
  cursor: pointer;
  transition: transform 180ms ease, border-color 180ms ease, background 180ms ease;
}

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

.primary {
  background: var(--accent);
  color: var(--accent-ink);
  border-color: transparent;
  font-weight: 850;
}

.ghost {
  color: var(--ink);
  background: rgba(255, 255, 255, 0.06);
}

.hero-stage {
  position: relative;
  min-height: clamp(34rem, 61vw, 52rem);
  perspective: 1200px;
}

.featured-agent {
  position: absolute;
  border: 1px solid rgba(255, 255, 255, 0.18);
  background: rgba(255, 255, 255, 0.06);
  color: var(--ink);
  box-shadow: var(--shadow);
  overflow: hidden;
  cursor: pointer;
  transform-style: preserve-3d;
  transition: transform 280ms ease, border-color 280ms ease, filter 280ms ease;
  animation: floaty 5s ease-in-out infinite;
}

.featured-agent::after,
.agent-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg, transparent 28%, rgba(255, 255, 255, 0.22), transparent 55%);
  transform: translateX(-120%);
  transition: transform 700ms ease;
}

.featured-agent:hover::after,
.agent-card:hover::after {
  transform: translateX(120%);
}

.featured-agent:hover {
  border-color: rgba(127, 240, 189, 0.65);
  filter: saturate(1.08);
}

.featured-agent img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.featured-agent span {
  position: absolute;
  left: 1rem;
  bottom: 1rem;
  padding: 0.45rem 0.7rem;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.46);
  backdrop-filter: blur(12px);
  font-weight: 850;
}

.feature-a {
  width: min(38vw, 28rem);
  aspect-ratio: 0.82;
  right: 14%;
  top: 1%;
  border-radius: 1.6rem;
  transform: rotateY(-12deg) rotateZ(3deg);
}

.feature-b {
  width: min(33vw, 23rem);
  aspect-ratio: 0.86;
  left: 0;
  top: 20%;
  border-radius: 1.4rem;
  transform: rotateY(12deg) rotateZ(-5deg);
  animation-delay: -1.3s;
}

.feature-c {
  width: min(29vw, 20rem);
  aspect-ratio: 0.9;
  right: 1%;
  bottom: 1%;
  border-radius: 1.2rem;
  transform: rotateY(-18deg) rotateZ(8deg);
  animation-delay: -2.2s;
}

.signal-panel {
  position: absolute;
  left: 24%;
  bottom: 9%;
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  padding: 0.75rem 0.9rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(16, 20, 18, 0.74);
  backdrop-filter: blur(16px);
  color: var(--muted);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.25);
}

.signal-dot,
.pulse {
  width: 0.65rem;
  height: 0.65rem;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 0 rgba(127, 240, 189, 0.55);
  animation: ping 1.8s infinite;
}

.section {
  padding: clamp(4rem, 8vw, 8rem) clamp(1rem, 5vw, 5rem);
}

.intro-strip {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(18rem, 0.85fr);
  gap: clamp(2rem, 5vw, 5rem);
  align-items: end;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.035);
}

.intro-strip p:not(.eyebrow),
.demo-copy + .demo-lines,
.viewer-content p {
  color: var(--muted);
  line-height: 1.65;
}

.section-heading {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 1.25rem;
  margin-bottom: 2rem;
}

.section-heading h2 {
  max-width: 54rem;
}

.filter-bar {
  display: flex;
  gap: 0.45rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.filter {
  min-height: 2.5rem;
  padding: 0.55rem 0.8rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: var(--muted);
  background: rgba(255, 255, 255, 0.04);
  cursor: pointer;
}

.filter.active {
  background: var(--ink);
  color: #111614;
}

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

.agent-card {
  position: relative;
  min-height: 31rem;
  display: flex;
  align-items: end;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 1.2rem;
  background: var(--panel);
  cursor: pointer;
  box-shadow: 0 18px 60px rgba(0, 0, 0, 0.22);
  isolation: isolate;
  transform: translateY(16px);
  opacity: 0;
  animation: cardIn 700ms ease forwards;
}

.agent-card:nth-child(2n) {
  min-height: 27rem;
}

.agent-card:nth-child(3n) {
  min-height: 35rem;
}

.agent-card img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: -2;
  transform: scale(1.02);
  transition: transform 500ms ease, filter 500ms ease;
}

.agent-card::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.88), rgba(0, 0, 0, 0.2) 54%, rgba(0, 0, 0, 0.02));
}

.agent-card:hover img {
  transform: scale(1.08);
  filter: saturate(1.08) contrast(1.04);
}

.agent-info {
  width: 100%;
  padding: 1rem;
}

.agent-meta {
  display: inline-flex;
  margin-bottom: 0.7rem;
  padding: 0.4rem 0.62rem;
  border-radius: 999px;
  color: var(--accent);
  background: rgba(0, 0, 0, 0.38);
  border: 1px solid rgba(255, 255, 255, 0.14);
  font-size: 0.75rem;
  font-weight: 850;
}

.agent-info h3 {
  margin-bottom: 0.35rem;
  font-size: clamp(1.35rem, 2.2vw, 2.15rem);
}

.agent-info p {
  margin-bottom: 1rem;
  color: rgba(246, 243, 234, 0.76);
  line-height: 1.45;
}

.talk-line {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  color: var(--ink);
  font-weight: 850;
}

.talk-line span:last-child {
  width: 2.25rem;
  aspect-ratio: 1;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: var(--accent);
  color: var(--accent-ink);
}

.demo-band {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(20rem, 1.05fr);
  gap: clamp(2rem, 5vw, 5rem);
  align-items: center;
  border-top: 1px solid var(--line);
}

.demo-lines {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.8rem;
}

.demo-lines span {
  min-height: 5.5rem;
  display: flex;
  align-items: center;
  padding: 1rem;
  border-bottom: 1px solid var(--line);
  color: var(--ink);
  font-size: clamp(1.1rem, 2vw, 1.75rem);
  font-weight: 850;
}

.viewer {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: grid;
  place-items: center;
  padding: 1rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 220ms ease;
}

.viewer.open {
  opacity: 1;
  pointer-events: auto;
}

.viewer-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.72);
  backdrop-filter: blur(16px);
}

.viewer-panel {
  position: relative;
  width: min(74rem, 100%);
  max-height: min(45rem, calc(100svh - 2rem));
  display: grid;
  grid-template-columns: minmax(16rem, 0.9fr) minmax(0, 1.1fr);
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 1.5rem;
  background: rgba(13, 17, 15, 0.92);
  box-shadow: var(--shadow);
  transform: translateY(20px) scale(0.98);
  transition: transform 220ms ease;
}

.viewer.open .viewer-panel {
  transform: translateY(0) scale(1);
}

.close-viewer {
  position: absolute;
  top: 0.8rem;
  right: 0.8rem;
  z-index: 2;
  width: 2.55rem;
  height: 2.55rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.34);
  color: var(--ink);
  font-size: 1.5rem;
  cursor: pointer;
}

.viewer-portrait {
  min-height: 100%;
  background: #050706;
}

.viewer-portrait img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.viewer-content {
  padding: clamp(1.3rem, 3vw, 3rem);
  overflow: auto;
}

.viewer-content h2 {
  margin-bottom: 1rem;
}

.viewer-descriptor {
  font-size: 1.1rem;
  color: var(--ink) !important;
}

.prompt-box,
.widget-shell {
  margin-top: 1.25rem;
  border-top: 1px solid var(--line);
  padding-top: 1.2rem;
}

.prompt-list {
  display: flex;
  gap: 0.55rem;
  flex-wrap: wrap;
}

.prompt-list button {
  min-height: 2.45rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  color: var(--ink);
  cursor: pointer;
  padding: 0.55rem 0.75rem;
}

.widget-shell {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(13rem, 1fr);
  gap: 1rem;
  align-items: stretch;
}

.widget-placeholder {
  min-height: 10rem;
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 0.5rem;
  padding: 1rem;
  border: 1px dashed rgba(127, 240, 189, 0.55);
  border-radius: 1rem;
  background: rgba(127, 240, 189, 0.07);
  text-align: center;
}

.widget-placeholder small {
  color: var(--muted);
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes floaty {
  0%,
  100% {
    translate: 0 0;
  }
  50% {
    translate: 0 -16px;
  }
}

@keyframes drift {
  to {
    transform: translate3d(5rem, 2rem, 0) scale(1.08);
  }
}

@keyframes ping {
  70% {
    box-shadow: 0 0 0 12px rgba(127, 240, 189, 0);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(127, 240, 189, 0);
  }
}

@keyframes cardIn {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 980px) {
  .hero,
  .intro-strip,
  .demo-band,
  .viewer-panel {
    grid-template-columns: 1fr;
  }

  .hero {
    padding-top: 5.4rem;
    gap: 0.5rem;
  }

  .hero-stage {
    order: -1;
    min-height: 31rem;
  }

  .hero-copy {
    max-width: 42rem;
  }

  h1 {
    font-size: clamp(3.1rem, 12vw, 6.4rem);
  }

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

  .viewer-panel {
    overflow: auto;
  }

  .viewer-portrait {
    max-height: 18rem;
  }
}

@media (max-width: 680px) {
  .site-header {
    position: absolute;
  }

  nav a {
    display: none;
  }

  .hero {
    min-height: auto;
    padding: 4.75rem 1rem 2.5rem;
  }

  .hero-stage {
    min-height: 28rem;
    margin-inline: -0.5rem;
  }

  .feature-a {
    width: 54vw;
    right: 0;
    top: 0;
  }

  .feature-b {
    width: 43vw;
    left: 1%;
    top: 25%;
  }

  .feature-c {
    width: 36vw;
    right: 8%;
    bottom: 0;
  }

  .signal-panel {
    left: 0.5rem;
    bottom: 0.4rem;
  }

  .hero-copy {
    margin-top: 0.35rem;
  }

  .eyebrow {
    margin-bottom: 0.7rem;
  }

  h1 {
    margin-bottom: 0.8rem;
    font-size: clamp(3.15rem, 15vw, 4.8rem);
  }

  .hero-text {
    line-height: 1.45;
  }

  .hero-actions {
    margin-top: 1.15rem;
  }

  .section-heading {
    align-items: start;
    flex-direction: column;
  }

  .filter-bar {
    justify-content: flex-start;
  }

  .agent-grid,
  .demo-lines,
  .widget-shell {
    grid-template-columns: 1fr;
  }

  .agent-card,
  .agent-card:nth-child(2n),
  .agent-card:nth-child(3n) {
    min-height: 30rem;
  }

  .viewer {
    padding: 0.55rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 1ms !important;
    scroll-behavior: auto !important;
    transition-duration: 1ms !important;
  }
}
