:root { color-scheme: dark; --fg: #fff; --muted: rgba(255, 255, 255, .74); --faint: rgba(255, 255, 255, .5); --line: rgba(255, 255, 255, .28); --rule: rgba(255, 255, 255, .12); --bg: #07121f; }
* { box-sizing: border-box; margin: 0; }
body { font-family: -apple-system, BlinkMacSystemFont, "Inter", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif; color: var(--fg); background: var(--bg); -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; }
a { color: inherit; }

/* home: the image covers the first screen only; everything below sits on the base color */
.bg { position: absolute; top: 0; left: 0; right: 0; height: 100svh; height: 100dvh; z-index: -1; overflow: hidden; }
.bg img { width: 100%; height: 100%; object-fit: cover; object-position: center 60%; display: block; }
.bg::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 28%; background: linear-gradient(to bottom, rgba(7, 18, 31, 0), var(--bg)); }
body.home { position: relative; min-height: 100svh; min-height: 100dvh; display: flex; flex-direction: column; }
.home main { flex: 1 0 auto; display: flex; flex-direction: column; width: 100%; max-width: calc(34rem + 2 * clamp(1.5rem, 8vw, 10rem)); }
.hero { flex: 1 0 auto; padding: 8vh clamp(1.5rem, 8vw, 10rem); display: flex; flex-direction: column; justify-content: center; align-items: flex-start; text-align: left; }
h1 { font-size: clamp(1.9rem, 4.2vw, 3.6rem); font-weight: 600; letter-spacing: -.02em; line-height: 1.08; text-wrap: balance; }
.lead { margin-top: 1.6rem; max-width: 30rem; font-size: 1.02rem; line-height: 1.6; color: var(--muted); text-wrap: pretty; }
.lead + .lead { margin-top: 1rem; }
.lead a { color: var(--fg); text-decoration: none; border-bottom: 1px solid var(--line); }
.lead a:hover { border-color: var(--fg); }
.endpoint { margin-top: 1.4rem; appearance: none; background: none; border: 0; border-bottom: 1px solid var(--line); padding: .35rem 0; color: var(--fg); font: .92rem ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; letter-spacing: .01em; cursor: pointer; transition: border-color .2s, color .2s; }
.endpoint:hover, .endpoint:focus-visible { border-color: var(--fg); outline: none; }
.endpoint[data-state="copied"] { color: var(--muted); }
.hint { margin-top: .6rem; font-size: .75rem; color: var(--faint); min-height: 1rem; }
.views { position: absolute; top: 1.25rem; right: clamp(1.25rem, 3vw, 2.5rem); z-index: 2; display: flex; align-items: center; gap: .6rem; font-size: .76rem; color: var(--faint); letter-spacing: .02em; text-shadow: 0 1px 3px rgba(0, 0, 0, .55); }
.views button { appearance: none; background: none; border: 0; padding: .2rem 0; font: inherit; color: var(--faint); cursor: pointer; border-bottom: 1px solid transparent; transition: color .2s, border-color .2s; }
.views button:hover, .views button:focus-visible { color: var(--fg); outline: none; }
.views button[aria-pressed="true"] { color: var(--fg); border-bottom-color: var(--line); cursor: default; }
/* agent view: the hero gives up the full screen and the image steps back */
.bg img { transition: opacity .5s, filter .5s; }
.agent-view .bg img { opacity: .28; filter: saturate(.5); }
.agent-view .bg::after { height: 45%; }
.agent-view .hero { flex: 0 0 auto; padding-top: 12vh; padding-bottom: 1rem; justify-content: flex-start; }

/* the agent section: quiet, small, below the fold */
.agents { padding: 2.5rem clamp(1.5rem, 8vw, 10rem) 4rem; font-size: .93rem; line-height: 1.6; color: var(--muted); }
.agents h2 { font-size: 1rem; font-weight: 600; color: var(--fg); letter-spacing: .01em; margin: 2.6rem 0 .8rem; }
.agents h2:first-child { margin-top: 0; }
.agents h3 { font-size: .8rem; font-weight: 600; color: var(--faint); text-transform: uppercase; letter-spacing: .08em; margin: 1.6rem 0 .5rem; }
.agents p, .agents li { max-width: 34rem; margin-bottom: .7rem; }
.agents ul { padding-left: 1.1rem; }
.agents code { font: .88em ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; color: var(--fg); overflow-wrap: anywhere; }
.agents a { color: var(--fg); text-decoration: none; border-bottom: 1px solid var(--line); }
.agents a:hover { border-color: var(--fg); }
.faq { max-width: 34rem; border-top: 1px solid var(--rule); }
.faq:last-of-type { border-bottom: 1px solid var(--rule); }
.faq summary { display: flex; justify-content: space-between; gap: 1rem; padding: .8rem 0; color: var(--fg); cursor: pointer; list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--faint); flex: 0 0 auto; }
.faq[open] summary::after { content: "\2212"; }
.faq p { padding-bottom: .5rem; }

footer nav { display: flex; justify-content: center; flex-wrap: wrap; gap: 1.6rem; padding: 1.4rem 1rem; padding-bottom: max(1.6rem, env(safe-area-inset-bottom)); font-size: .76rem; }
footer a { color: var(--faint); text-decoration: none; transition: color .2s; }
footer a:hover { color: var(--fg); }

/* documents */
.doc main { max-width: 42rem; margin: 0 auto; padding: 4rem 1.5rem 6rem; line-height: 1.65; }
.doc .back { display: inline-block; margin-bottom: 2.5rem; font-size: .85rem; color: var(--faint); text-decoration: none; }
.doc .back:hover { color: var(--fg); }
.doc h1 { font-size: 1.9rem; margin-bottom: .4rem; }
.doc .meta { color: var(--faint); font-size: .85rem; margin-bottom: 2.2rem; }
.doc h2 { font-size: 1.1rem; margin: 2.1rem 0 .6rem; }
.doc p, .doc li { color: var(--muted); margin-bottom: .8rem; }
.doc ul { padding-left: 1.2rem; }
.doc a { color: var(--fg); }
.doc address { font-style: normal; color: var(--muted); line-height: 1.7; }
.doc pre { margin: 1rem 0; padding: .9rem 1rem; overflow-x: auto; background: rgba(255, 255, 255, .04); border: 1px solid var(--rule); border-radius: .4rem; }
.doc pre code { font: .82rem ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; color: var(--fg); white-space: pre; }
.doc code { font: .88em ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; }

@media (max-width: 600px) {
  .bg img { object-position: 22% 60%; }
  .hero { padding: 8vh 1.4rem; }
  .agents { padding: 2rem 1.4rem 3rem; }
  .endpoint { font-size: .8rem; white-space: normal; word-break: break-all; }
  footer nav { gap: 1rem; padding-top: 1.1rem; padding-bottom: max(1.1rem, env(safe-area-inset-bottom)); }
}
@media (min-width: 1600px) {
  .home main { max-width: calc(38rem + 20rem); }
  h1 { font-size: 4rem; }
  .lead { font-size: 1.15rem; max-width: 34rem; }
  .endpoint { font-size: 1rem; }
  .agents { font-size: 1.02rem; }
  .agents p, .agents li, .faq { max-width: 38rem; }
  footer nav { font-size: .85rem; }
}
@media (max-height: 620px) {
  /* short viewports (phone landscape): tighter, so one screen still holds it */
  .hero { padding-top: 2rem; padding-bottom: .75rem; }
  h1 { font-size: clamp(1.6rem, 3.4vw, 2.2rem); }
  .lead { margin-top: 1rem; font-size: .95rem; }
  .lead + .lead { margin-top: .6rem; }
  .endpoint { margin-top: 1rem; }
  .hint { min-height: .5rem; }
  footer nav { padding-top: .7rem; padding-bottom: max(.8rem, env(safe-area-inset-bottom)); }
}
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
.doc table { width: 100%; margin: 1rem 0; border-collapse: collapse; font-size: .9rem; }
.doc th, .doc td { padding: .5rem .6rem .5rem 0; text-align: left; border-bottom: 1px solid var(--rule); color: var(--muted); }
.doc th { color: var(--fg); font-weight: 600; }
