:root {
  --bg: #0F100E;
  --text: #EEEAE0;
  --muted: #B4AFA3;
  --dim: #7d796f;
  --line: rgba(238, 232, 218, 0.11);
  --line-2: rgba(238, 232, 218, 0.22);
  --fill: rgba(238, 232, 218, 0.03);
  --fill-2: rgba(238, 232, 218, 0.06);
  --teal: #62A7B3;
  --pink: #E8566F;
  --pink-bg: rgba(232, 86, 111, 0.14);
  --grad: linear-gradient(100deg, #F2925A 0%, #E8566F 55%, #D6447F 100%);
  --r: 2px;
  --r-frame: 4px;
  --wrap: 1200px;
  --sans: "Instrument Sans", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  --mono: "Geist Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 15px;
  font-weight: 400;
  line-height: 1.55;
  letter-spacing: -0.01em;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
h1, h2, h3 { margin: 0; font-weight: 400; line-height: 1.1; }
p, ul, ol { margin: 0; }
img { display: block; }
[hidden] { display: none !important; }
:focus-visible { outline: 1px solid var(--text); outline-offset: 3px; }

.ico { width: 16px; height: 16px; fill: currentColor; flex: none; }
.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 32px; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 40px; padding: 0 18px; border-radius: var(--r);
  font: inherit; font-size: 14px; font-weight: 500; letter-spacing: -0.01em; white-space: nowrap;
  border: 1px solid transparent; cursor: pointer;
  transition: background-color .15s ease, border-color .15s ease, color .15s ease, opacity .15s ease;
}
.btn-lg { height: 46px; padding: 0 22px; font-size: 15px; }
.btn-primary { background: var(--text); color: var(--bg); border-color: var(--text); }
.btn-primary:hover { background: #fff; border-color: #fff; }
.btn-outline { background: transparent; color: var(--text); border-color: var(--line-2); }
.btn-outline:hover { border-color: rgba(238, 232, 218, 0.45); }
.btn.is-disabled, .btn:disabled {
  background: transparent; color: var(--dim); border-color: var(--line); cursor: not-allowed;
}
.btn.is-ending { background: transparent; color: var(--text); border-color: var(--line-2); }

/* Chips */
.chip {
  display: inline-flex; align-items: center; gap: 6px; align-self: flex-start;
  height: 22px; padding: 0 7px; border-radius: var(--r);
  font-family: var(--mono); font-size: 12px; letter-spacing: 0.02em; text-transform: uppercase; line-height: 1;
}
.chip-cream { background: var(--text); color: var(--bg); }
.chip-accent { background: var(--pink-bg); color: #F3A0AE; }
.chip-outline { border: 1px solid var(--line-2); color: var(--muted); }

.live-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--pink); flex: none; animation: blink 1.6s ease-in-out infinite; }

/* Announcement */
.announce { border-bottom: 1px solid var(--line); }
.announce-inner { display: flex; align-items: center; justify-content: center; gap: 12px; min-height: 44px; padding-top: 8px; padding-bottom: 8px; font-size: 14px; color: var(--muted); text-align: center; }
.announce-link { color: var(--teal); white-space: nowrap; }
.announce-link:hover { color: var(--text); }

/* Nav */
.nav { position: sticky; top: 0; z-index: 20; background: var(--bg); border-bottom: 1px solid var(--line); }
.nav-inner { display: flex; align-items: center; gap: 40px; height: 64px; }
.logo { display: inline-flex; align-items: center; flex: none; }
.logo img { width: 94px; height: 18px; }
.nav-links { display: flex; gap: 28px; }
.nav-links a { color: var(--muted); font-size: 15px; transition: color .15s; }
.nav-links a:hover { color: var(--text); }
.nav-actions { display: flex; gap: 10px; margin-left: auto; }

/* Hero */
.hero { padding: 132px 0 120px; text-align: center; }
.hero-inner { display: flex; flex-direction: column; align-items: center; }
.eyebrow { font-family: var(--mono); font-size: 13px; text-transform: uppercase; letter-spacing: 0.02em; color: var(--muted); }
.hero-title {
  margin-top: 28px; max-width: 1000px;
  font-size: clamp(48px, 8.2vw, 92px); letter-spacing: -0.055em; line-height: 0.98;
}
.grad { background: var(--grad); -webkit-background-clip: text; background-clip: text; color: transparent; padding-right: 0.04em; }
.hero-sub { margin-top: 28px; max-width: 620px; color: var(--muted); font-size: 17px; line-height: 1.5; }
.hero-ctas { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 40px; }
.talk-inline-msg { margin-top: 16px; color: var(--muted); font-size: 14px; }
.talk-inline-msg.is-error { color: #F3A0AE; }

/* Contract pill */
.ca-pill {
  display: inline-flex; align-items: center; gap: 12px; max-width: 100%;
  margin-top: 48px; padding: 0 4px 0 12px; min-height: 36px;
  border: 1px solid var(--line); border-radius: var(--r);
  font-family: var(--mono); font-size: 12px;
}
.ca-label { color: var(--dim); text-transform: uppercase; letter-spacing: 0.02em; white-space: nowrap; }
.ca-value { font-family: var(--mono); font-size: 13px; color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.ca-pill:not(.has-mint) .ca-value { color: var(--muted); padding-right: 8px; }
.ca-copy {
  flex: none; height: 26px; padding: 0 8px; border-radius: var(--r); cursor: pointer;
  border: 1px solid var(--line-2); background: transparent; color: var(--text);
  font-family: var(--mono); font-size: 12px; text-transform: uppercase; letter-spacing: 0.02em;
}
.ca-copy:hover { background: var(--fill-2); }
.ca-copy.is-copied { color: var(--teal); border-color: var(--teal); }

/* Sections */
.section { padding: 64px 0 72px; }
.section-title { display: flex; align-items: center; gap: 20px; margin-bottom: 28px; }
.section-title h2 { font-size: 28px; letter-spacing: -0.035em; white-space: nowrap; }
.rule { flex: 1 1 auto; height: 1px; background: var(--line); min-width: 24px; }
.section-link { font-size: 15px; color: var(--text); white-space: nowrap; }
.section-link:hover { color: var(--muted); }
.section-meta { font-family: var(--mono); font-size: 12px; text-transform: uppercase; letter-spacing: 0.02em; color: var(--dim); white-space: nowrap; }
.lead { max-width: 640px; color: var(--muted); font-size: 15px; margin-bottom: 32px; }

/* Cards */
.grid { list-style: none; padding: 0; display: grid; gap: 16px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.card {
  display: flex; flex-direction: column; gap: 12px;
  padding: 24px; border: 1px solid var(--line); border-radius: var(--r); background: var(--fill);
  transition: border-color .15s ease;
}
.card:hover { border-color: var(--line-2); }
.card h3 { margin-top: 16px; font-size: 20px; letter-spacing: -0.03em; line-height: 1.2; }
.card p { color: var(--muted); font-size: 15px; }
.card-k { font-family: var(--mono); font-size: 12px; text-transform: uppercase; letter-spacing: 0.02em; color: var(--teal); }

/* Live */
.stage {
  position: relative; aspect-ratio: 16 / 9; width: 100%;
  border-radius: var(--r-frame); overflow: hidden;
  border: 1px solid var(--line); background: #000;
}
.stage-frame { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; display: block; }
.stage .chip-live {
  position: absolute; top: 14px; left: 14px; z-index: 2; pointer-events: none;
  background: var(--bg); color: var(--text); border: 1px solid var(--line-2); height: 24px;
}
.stage .chip-demo {
  position: absolute; top: 14px; left: 86px; z-index: 2; pointer-events: none; height: 24px;
  background: rgba(98,167,179,.16); color: #62A7B3;
}
.stage .chip-demo[hidden] { display: none; }
.note { margin-top: 14px; color: var(--dim); font-size: 14px; }

/* Talk */
.talk-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: start; }
.facts { list-style: none; padding: 0; border-top: 1px solid var(--line); }
.facts li { display: flex; gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--line); color: var(--text); }
.facts-k { font-family: var(--mono); font-size: 12px; color: var(--teal); padding-top: 3px; }
.talk-card {
  --level: 0;
  display: flex; flex-direction: column; align-items: center;
  padding: 24px; border: 1px solid var(--line); border-radius: var(--r); background: var(--fill);
}
.talk-top { display: flex; justify-content: space-between; align-items: center; width: 100%; }
.talk-status {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--mono); font-size: 12px; text-transform: uppercase; letter-spacing: 0.02em; color: var(--muted);
}
.talk-status::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--dim); }
.talk-card[data-state="connecting"] .talk-status::before { background: #F2925A; animation: blink 1s infinite; }
.talk-card[data-state="live"] .talk-status { color: var(--text); }
.talk-card[data-state="live"] .talk-status::before { background: var(--pink); animation: blink 1.6s ease-in-out infinite; }
.talk-card[data-state="error"] .talk-status { color: #F3A0AE; }
.talk-card[data-state="error"] .talk-status::before { background: var(--pink); }
.talk-timer { font-family: var(--mono); font-size: 12px; color: var(--muted); }

.orb-wrap { position: relative; width: 200px; height: 200px; margin: 24px 0; display: grid; place-items: center; }
.orb-ring {
  position: absolute; inset: 30px; border-radius: 50%;
  border: 1px solid var(--line-2);
  transform: scale(calc(1 + var(--level) * 0.6));
  transition: transform .08s linear, border-color .2s;
}
.orb-ring-2 { inset: 8px; border-color: var(--line); transform: scale(calc(1 + var(--level) * 0.3)); }
.talk-card[data-state="live"] .orb-ring { border-color: rgba(232, 86, 111, 0.6); }
.talk-card[data-state="live"] .orb-ring-2 { border-color: rgba(242, 146, 90, 0.35); }
.talk-card[data-state="connecting"] .orb-ring { border-top-color: var(--text); animation: spin 1.1s linear infinite; }
.orb {
  position: relative; z-index: 1; width: 104px; height: 104px; border-radius: 50%;
  display: grid; place-items: center; cursor: pointer;
  border: 1px solid var(--line-2); background: var(--bg); color: var(--text);
  transition: background-color .15s, border-color .15s;
}
.orb .ico { width: 32px; height: 32px; }
.orb:hover { background: var(--fill-2); border-color: rgba(238, 232, 218, 0.45); }
.orb:disabled { cursor: not-allowed; color: var(--dim); }
.talk-card[data-state="live"] .orb { background: var(--grad); color: var(--bg); border-color: transparent; }

.talk-card-btn { min-width: 160px; }
.talk-error { margin-top: 14px; color: #F3A0AE; font-size: 14px; text-align: center; }

.transcript {
  width: 100%; margin-top: 24px; height: 220px; overflow-y: auto;
  padding: 14px; border: 1px solid var(--line); border-radius: var(--r); background: var(--bg);
  display: flex; flex-direction: column; gap: 10px;
  scrollbar-width: thin; scrollbar-color: var(--line-2) transparent;
}
.transcript-empty { margin: auto; color: var(--dim); font-size: 14px; text-align: center; }
.line { max-width: 88%; padding: 8px 12px; border-radius: var(--r); font-size: 14px; line-height: 1.5; overflow-wrap: anywhere; }
.line-agent { align-self: flex-start; border: 1px solid var(--line-2); color: var(--text); }
.line-user { align-self: flex-end; background: var(--fill-2); color: var(--muted); }
.line-who { display: block; font-family: var(--mono); font-size: 11px; text-transform: uppercase; letter-spacing: 0.02em; color: var(--dim); margin-bottom: 2px; }
.line-agent .line-who { color: var(--teal); }

/* Token */
.token-grid { display: flex; flex-direction: column; gap: 16px; }
.token-bar { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.ca-pill-block { margin: 0; flex: 1 1 360px; min-height: 40px; }

/* Developers */
.dev-grid { display: grid; grid-template-columns: 1fr 1.25fr; gap: 48px; align-items: start; }
.dev-links { display: flex; gap: 10px; flex-wrap: wrap; }
.code-card { min-width: 0; border: 1px solid var(--line); border-radius: var(--r); background: var(--fill); }
.code-head { display: flex; align-items: center; gap: 12px; padding: 0 8px 0 14px; height: 40px; border-bottom: 1px solid var(--line); }
.code-title { font-family: var(--mono); font-size: 12px; text-transform: uppercase; letter-spacing: 0.02em; color: var(--dim); }
.code-copy {
  margin-left: auto; height: 26px; padding: 0 8px; border-radius: var(--r); cursor: pointer;
  border: 1px solid var(--line-2); background: transparent; color: var(--muted);
  font-family: var(--mono); font-size: 12px; text-transform: uppercase; letter-spacing: 0.02em;
}
.code-copy:hover { color: var(--text); }
.code-copy.is-copied { color: var(--teal); border-color: var(--teal); }
.code { margin: 0; padding: 18px; overflow-x: auto; font-family: var(--mono); font-size: 13px; line-height: 1.75; letter-spacing: 0; color: var(--muted); }
.c-cmd { color: var(--text); }
.c-str { color: var(--teal); }

/* Footer */
.footer { padding: 48px 0 64px; border-top: 1px solid var(--line); margin-top: 56px; }
.footer-top { display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap; }
.footer-links { display: flex; gap: 28px; }
.footer-links a { color: var(--muted); font-size: 15px; }
.footer-links a:hover { color: var(--text); }
.disclaimer { margin-top: 32px; max-width: 760px; color: var(--dim); font-size: 13px; line-height: 1.6; }

@keyframes blink { 50% { opacity: 0.35; } }
@keyframes spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
}

/* Responsive */
@media (max-width: 1040px) {
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .talk-grid, .dev-grid { grid-template-columns: 1fr; gap: 32px; }
}
@media (max-width: 860px) {
  .nav-links { display: none; }
  .grid-3 { grid-template-columns: 1fr; }
  .hero { padding: 88px 0 80px; }
}
@media (max-width: 560px) {
  .wrap { padding: 0 18px; }
  .announce-inner { font-size: 13px; flex-wrap: wrap; gap: 6px 10px; }
  .nav-talk { display: none; }
  .grid-4 { grid-template-columns: 1fr; }
  .hero-ctas { width: 100%; flex-direction: column; }
  .hero-ctas .btn { width: 100%; }
  .hero-sub { font-size: 16px; }
  .section-title { gap: 14px; }
  .section-title h2 { font-size: 24px; white-space: normal; }
  .section-meta { display: none; }
  .ca-pill { flex-wrap: wrap; justify-content: center; padding: 10px 12px; gap: 8px 10px; }
  .ca-pill .ca-label { width: 100%; text-align: center; }
  .ca-pill .ca-value { max-width: 100%; }
  .ca-pill-block { justify-content: flex-start; flex-basis: 100%; }
  .ca-pill-block .ca-label { text-align: left; }
  .token-bar .btn { width: 100%; }
  .talk-card { padding: 18px; }
  .orb-wrap { width: 170px; height: 170px; margin: 18px 0; }
  .orb { width: 92px; height: 92px; }
  .code { font-size: 12px; padding: 14px; }
}
