/* One dark scheme, in the app's own dark colors: black, its greys and its blue. */
:root {
  --bg: #000000;
  --ink: #ffffff;
  --ink-2: #98989f;
  --line: #1f1f22;
  --field: #1c1c1e;
  --bubble: #262629;
  --accent: #2a62d4;
  --link: #7eaaff;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 17px/1.5 -apple-system, BlinkMacSystemFont, "SF Pro Text", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}
main, .bar, footer { width: min(1080px, 100% - 48px); margin: 0 auto; }
a { color: var(--link); text-underline-offset: 3px; }
a:focus-visible { outline: 2px solid var(--link); outline-offset: 4px; border-radius: 6px; }
h1, h2, h3, p, ul, ol, dl, dd { margin: 0; padding: 0; }
ul, ol { list-style: none; }
h1, h2 { font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", system-ui, sans-serif; font-weight: 600; text-wrap: balance; }

.bar { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); font-weight: 600; text-decoration: none; }
.brand img { border-radius: 7px; }
.bar nav, footer nav { display: flex; gap: 28px; }
.bar nav a, footer a { color: var(--ink-2); font-size: 15px; text-decoration: none; }
.bar nav a:hover, footer a:hover { color: var(--ink); }

/* The hero: what Sidebots is, the download, and the app's home screen rising out of a blue light. */
.hero { display: flex; flex-direction: column; align-items: center; text-align: center; padding-top: 88px; }
h1 { max-width: 11em; font-size: clamp(44px, 7.4vw, 88px); line-height: 1.02; letter-spacing: -0.045em; }
.lede { margin-top: 24px; max-width: 31em; font-size: 20px; line-height: 1.45; color: var(--ink-2); text-wrap: balance; }
.actions { margin-top: 36px; display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 14px 28px; }
.download {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 13px 22px;
  border-radius: 12px;
  background: var(--accent);
  box-shadow: inset 0 1px 0 rgb(255 255 255 / 0.18);
  color: #ffffff;
  font-weight: 600;
  text-decoration: none;
}
.download:hover { filter: brightness(1.12); }
.quiet { color: var(--ink-2); font-size: 16px; }
.quiet:hover { color: var(--ink); }
.fine { margin-top: 20px; font-size: 14px; color: var(--ink-2); }

.stage {
  position: relative;
  width: 100%;
  height: 560px;
  margin-top: 72px;
  display: flex;
  justify-content: center;
  overflow: hidden;
  border-bottom: 1px solid var(--line);
  -webkit-mask-image: linear-gradient(#000 70%, transparent);
  mask-image: linear-gradient(#000 70%, transparent);
}
.stage::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(48% 80% at 50% 70%, rgb(42 98 212 / 0.7), transparent 72%);
}
.phone {
  position: relative;
  flex: none;
  width: 372px;
  height: 780px;
  padding: 11px;
  border-radius: 58px;
  background: #18181a;
  box-shadow: 0 0 0 1px #3a3a3e, 0 40px 120px rgb(0 0 0 / 0.6);
  text-align: left;
}
.screen { position: relative; height: 100%; border-radius: 47px; background: #000000; overflow: hidden; }
.status { display: flex; align-items: center; justify-content: space-between; height: 54px; padding: 4px 30px 0; font-size: 16px; font-weight: 600; }
.island { width: 104px; height: 30px; border-radius: 15px; background: #18181a; }
.signal { display: flex; align-items: flex-end; gap: 2.5px; }
.signal i { width: 3.5px; border-radius: 1px; background: #ffffff; }
.signal i:nth-child(1) { height: 5px; }
.signal i:nth-child(2) { height: 7.5px; }
.signal i:nth-child(3) { height: 10px; }
.signal i:nth-child(4) { height: 12.5px; }
.add { width: 44px; height: 44px; margin: 4px 16px 10px auto; border-radius: 22px; background: var(--field); display: grid; place-items: center; color: var(--link); }
.chats li { display: flex; align-items: center; gap: 12px; padding-left: 16px; }
.chat { flex: 1; min-width: 0; min-height: 76px; padding: 10px 16px 10px 0; border-bottom: 1px solid #2c2c2e; display: flex; flex-direction: column; justify-content: center; }
.top { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.top b { font-weight: 600; }
.top time { font-size: 15px; color: var(--ink-2); }
.bottom { display: flex; align-items: flex-start; gap: 10px; margin-top: 2px; }
.preview { flex: 1; font-size: 15px; line-height: 20px; height: 40px; color: var(--ink-2); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.preview.unread { color: var(--ink); }
.preview.working { font-style: italic; }
.count { min-width: 22px; height: 22px; padding: 0 7px; border-radius: 11px; background: var(--accent); font-size: 13px; font-weight: 600; line-height: 22px; text-align: center; }

/*
 * An agent's avatar, cut from its spritesheet as the app does: 8 cells across,
 * 192 by 208 each, with the 144-pixel drawing 24 in and 48 down, and one row
 * per state. At a third of its size, each drawing pixel is 3 screen pixels.
 */
.avatar {
  --scale: 0.3333;
  --frames: 6;
  --row: 0;
  --frame-ms: 450ms;
  display: inline-block;
  flex: none;
  width: calc(144px * var(--scale));
  height: calc(153px * var(--scale));
  background-image: var(--sheet);
  background-size: calc(1536px * var(--scale)) calc(832px * var(--scale));
  background-position-y: calc(-1 * (var(--row) * 208px + 39px) * var(--scale));
  image-rendering: pixelated;
  animation: frames calc(var(--frames) * var(--frame-ms)) steps(var(--frames)) infinite;
}
.avatar.working { --row: 1; --frame-ms: 150ms; }
.avatar.replied { --row: 2; --frame-ms: 300ms; }
@keyframes frames {
  from { background-position-x: calc(-24px * var(--scale)); }
  to { background-position-x: calc(-1 * (var(--frames) * 192px + 24px) * var(--scale)); }
}
@keyframes arrive { from { opacity: 0; transform: translateY(6px); } }
.arrive, .arrive + .count { animation: arrive 400ms ease-out; }
@media (prefers-reduced-motion: reduce) {
  .avatar { animation: none; background-position-x: calc(-24px * var(--scale)); }
}

/* A feature: a few words beside the part of the app they are about. */
.feature { display: grid; grid-template-columns: 1fr 1fr; align-items: center; gap: 72px; padding: 96px 0; border-bottom: 1px solid var(--line); }
.flip .words { order: 2; }
h2 { font-size: clamp(30px, 3.6vw, 42px); line-height: 1.08; letter-spacing: -0.035em; }
.words p { margin-top: 16px; max-width: 27em; font-size: 18px; color: var(--ink-2); }
.facts { margin-top: 24px; display: grid; gap: 10px; font-size: 16px; color: var(--ink-2); }
.facts li { padding-left: 26px; background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M3 8.5l3.200 3.200L13 5' fill='none' stroke='%237eaaff' stroke-width='1.75' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") 0 4px / 16px no-repeat; }
.shot {
  min-height: 400px;
  padding: 48px 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: radial-gradient(90% 90% at 50% 110%, rgb(42 98 212 / 0.34), transparent 70%), #050506;
}

.thread { width: min(380px, 100%); display: flex; flex-direction: column; gap: 6px; }
.who { align-self: center; display: flex; flex-direction: column; align-items: center; margin-bottom: 14px; }
.pill { margin-top: -5px; padding: 3px 11px; border-radius: 999px; background: var(--field); font-size: 12px; font-weight: 600; line-height: 16px; }
.bubble { max-width: 80%; padding: 8px 14px; border-radius: 20px; font-size: 17px; line-height: 22px; }
.mine { align-self: flex-end; background: var(--accent); border-bottom-right-radius: 6px; }
.theirs { width: fit-content; background: var(--bubble); border-bottom-left-radius: 6px; }
.receipt { align-self: flex-end; margin: -2px 4px 0 0; font-size: 11px; line-height: 15px; color: var(--ink-2); }
.answer { position: relative; margin-top: 6px; }
.busy { position: absolute; top: 4px; left: 2px; display: flex; align-items: center; gap: 10px; font-size: 15px; font-style: italic; color: var(--ink-2); opacity: 0; }

/* The chat plays out as it does on the phone: the message, its receipt, the agent at work, then the one reply in its place. */
.waiting .mine, .waiting .receipt, .waiting .theirs { opacity: 0; }
.playing .mine { animation: arrive 420ms ease-out both; }
.playing .receipt { animation: arrive 420ms ease-out 700ms both; }
.playing .busy { animation: busy 2600ms ease-out 1300ms both; }
.playing .theirs { animation: arrive 420ms ease-out 3900ms both; }
@keyframes busy { 0%, 100% { opacity: 0; } 12%, 88% { opacity: 1; } }

/* The panel Sidebots shows on the computer. */
.panel { width: 300px; padding: 6px; border: 1px solid #38383b; border-radius: 13px; background: #232325; box-shadow: 0 24px 80px rgb(0 0 0 / 0.5); font-size: 13px; line-height: 16px; }
.panel hr { margin: 6px 0; border: 0; border-top: 1px solid #3a3a3d; }
.panel h3 { padding: 0 10px 2px; font-size: 11px; font-weight: 600; color: var(--ink-2); }
.app { display: flex; align-items: center; gap: 10px; padding: 6px 10px 2px; }
.app img { border-radius: 8px; }
.app b { display: block; font-weight: 600; }
.app span { display: flex; align-items: center; gap: 5px; font-size: 12px; color: var(--ink-2); }
.dot { width: 7px; height: 7px; border-radius: 50%; background: #30d158; }
.item { display: flex; align-items: center; gap: 10px; padding: 4px 10px; }
.item small { display: block; font-size: 11px; color: var(--ink-2); }
.tile { flex: none; width: 26px; height: 26px; border-radius: 50%; background: rgb(255 255 255 / 0.1); display: grid; place-items: center; }
.tile svg { width: 14px; height: 14px; }
.change { margin-left: auto; padding: 2px 8px; border-radius: 5px; background: rgb(255 255 255 / 0.14); font-size: 11px; }
.plain { display: flex; align-items: center; justify-content: space-between; padding: 5px 10px; }
.plain kbd { font: inherit; color: var(--ink-2); }
.switch { width: 26px; height: 15px; border-radius: 8px; background: var(--accent); position: relative; }
.switch::after { content: ""; position: absolute; top: 1.5px; right: 1.5px; width: 12px; height: 12px; border-radius: 50%; background: #ffffff; }

/* An agent's jobs, as its page in the app lists them. */
.jobs { width: min(380px, 100%); }
.jobs h3 { padding: 0 16px 8px; font-size: 13px; font-weight: 400; color: var(--ink-2); }
.card { border-radius: 14px; background: var(--field); }
.job { padding: 12px 16px; display: grid; gap: 2px; }
.job + .job { border-top: 1px solid #2c2c2e; }
.job b { font-weight: 400; }
.job span { font-size: 14px; line-height: 19px; color: var(--ink-2); }

.setup, .know { padding: 104px 0; border-bottom: 1px solid var(--line); }
.setup ol { margin-top: 40px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px; counter-reset: step; }
.setup li { counter-increment: step; padding-top: 20px; border-top: 1px solid var(--line); color: var(--ink-2); }
.setup li::before { content: counter(step); display: block; margin-bottom: 14px; font-size: 14px; font-weight: 600; color: var(--link); font-variant-numeric: tabular-nums; }
.setup b, .know dt { display: block; margin-bottom: 4px; color: var(--ink); font-weight: 600; }
.know dl { margin-top: 40px; display: grid; grid-template-columns: 1fr 1fr; gap: 40px 64px; }
.know dd { max-width: 30em; color: var(--ink-2); }

.last { padding: 120px 0; display: flex; flex-direction: column; align-items: center; text-align: center; }
.last .download { margin-top: 32px; }

footer { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 28px 0 40px; border-top: 1px solid var(--line); font-size: 14px; color: var(--ink-2); }
footer span { display: flex; align-items: center; gap: 10px; }
footer img { border-radius: 5px; }

@media (max-width: 820px) {
  .hero { padding-top: 56px; }
  .lede { font-size: 18px; }
  .stage { height: 480px; margin-top: 56px; }
  .feature { grid-template-columns: 1fr; gap: 48px; padding: 72px 0; }
  .flip .words { order: 0; }
  .setup, .know { padding: 72px 0; }
  .setup ol, .know dl { grid-template-columns: 1fr; gap: 28px; }
  .last { padding: 88px 0; }
}
@media (max-width: 480px) {
  main, .bar, footer { width: calc(100% - 32px); }
  .phone { width: 340px; }
  footer { flex-direction: column; align-items: flex-start; }
}

/* The privacy policy: one readable column. */
.policy { max-width: 40em; padding: 56px 0 96px; }
.policy h1 { font-size: 44px; line-height: 1.05; letter-spacing: -0.035em; }
.policy h2 { font-size: 22px; line-height: 1.2; letter-spacing: -0.015em; margin-top: 44px; }
.policy p { margin-top: 12px; color: var(--ink-2); }
