:root {
  color-scheme: dark;
  --bg: #000;
  --surface: #2c2c2c;
  --text: #f0f0f0;
  --muted: #b0b0b0;
  --line: #404040;
  --accent: #d4d4d4;
  --radius: 8px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 86px; }

body {
  position: relative;
  isolation: isolate;
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Albert Sans", sans-serif;
  line-height: 1.5;
}

body::before {
  position: absolute;
  z-index: -1;
  inset: 0;
  background: url("../images/random-shapes.svg") 0 0 / 560px 560px repeat;
  filter: invert(1);
  opacity: .018;
  content: "";
  pointer-events: none;
}

a { color: inherit; }

.wrap {
  width: min(1240px, calc(100% - 48px));
  margin: 0 auto;
}

header {
  position: sticky;
  z-index: 20;
  top: 0;
  border-bottom: 1px solid var(--line);
  background: var(--bg);
  transition: transform .2s ease;
}

header.is-hidden { transform: translateY(-100%); }

.header-inner {
  min-height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo-placeholder {
  display: block;
  width: 112px;
  height: 30px;
  background: #fff;
}
.logo-placeholder:focus-visible { outline: 2px solid #fff; outline-offset: 4px; }

.header-nav {
  display: flex;
  align-items: center;
  gap: 30px;
  margin-left: auto;
}

.header-nav a {
  color: #b0b0b0;
  font-size: .86rem;
  font-weight: 600;
  text-decoration: none;
}

.header-nav a:hover { color: #fff; }
.header-nav a:focus-visible { outline: 2px solid #fff; outline-offset: 4px; }

.header-nav .nav-download {
  padding: 9px 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--text);
}

.language-switch {
  margin-left: 24px;
}
.language-toggle {
  display: flex;
  gap: 2px;
  padding: 3px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: #aaa;
  font-size: .75rem;
  font-weight: 700;
  text-decoration: none;
}
.language-toggle span {
  padding: 5px 7px;
  border-radius: 4px;
}
.language-toggle .is-current { background: #303030; color: #fff; }
.language-toggle:hover { color: #fff; }
.language-toggle:focus-visible { outline: 2px solid #fff; outline-offset: 2px; }

.button {
  display: inline-flex;
  min-height: 50px;
  align-items: center;
  justify-content: center;
  padding: 0 20px;
  border: 1px solid var(--accent);
  border-radius: var(--radius);
  background: var(--accent);
  color: #202020;
  font-weight: 750;
  text-decoration: none;
  transition: background-color .15s ease;
}

.button:hover { background: #f0f0f0; }

.button[aria-disabled="true"],
.button[aria-disabled="true"]:hover {
  background: var(--accent);
  opacity: .55;
  cursor: not-allowed;
  transform: none;
}

.button:focus-visible {
  outline: 2px solid #fff;
  outline-offset: 4px;
}

.hero {
  padding: 76px 24px 0;
  background: var(--bg);
  text-align: center;
}

.hero-backdrop {
  width: min(600px, 100%);
  margin: 0 auto;
  padding: 1px 12px;
  background: var(--bg);
}

.hero-backdrop, .capture-backdrop, .about, .self-hosted-backdrop, .advantages, .getting-started, .downloads, .download-backdrop {
  position: relative;
}

.hero-backdrop::before, .capture-backdrop::before, .about::before,
.self-hosted-backdrop::before, .advantages::before, .getting-started::before, .downloads::before, .download-backdrop::before {
  position: absolute;
  z-index: -1;
  inset: -90px 0;
  background: linear-gradient(to bottom, transparent, var(--bg) 90px, var(--bg) calc(100% - 90px), transparent);
  content: "";
  pointer-events: none;
}

.hero-backdrop::before, .capture-backdrop::before, .about::before, .self-hosted-backdrop::before, .advantages::before, .getting-started::before, .downloads::before, .download-backdrop::before {
  left: -54px;
  right: -54px;
  -webkit-mask-image: linear-gradient(to right, transparent, #000 54px, #000 calc(100% - 54px), transparent);
  mask-image: linear-gradient(to right, transparent, #000 54px, #000 calc(100% - 54px), transparent);
}

.capture-backdrop::before {
  left: max(0px, calc((100% - min(80vw, 1200px)) / 2 - 54px));
  right: max(0px, calc((100% - min(80vw, 1200px)) / 2 - 54px));
}

.eyebrow {
  margin: 0 0 16px;
  color: #a6a6a6;
  font-size: .75rem;
  font-weight: 800;
  letter-spacing: .15em;
  text-transform: uppercase;
}

h1 {
  width: 220px;
  height: 72px;
  margin: 0 auto;
  background: #fff;
}

.tagline {
  margin: 20px 0 0;
  color: #e5e5e5;
  font-size: clamp(1.25rem, 2.4vw, 1.8rem);
  font-weight: 600;
  letter-spacing: -.035em;
}

.hero-copy {
  max-width: 520px;
  margin: 12px auto 24px;
  color: var(--muted);
  font-size: 1rem;
}

.hero-note { margin: 11px 0 0; color: #aaa; font-size: .82rem; }

.capture-backdrop {
  padding: 64px 0 0;
  background: var(--bg);
}

figure {
  position: relative;
  margin: 0 auto;
  line-height: 0;
}

.capture-image {
  position: relative;
  width: min(80vw, 1200px);
  margin: 0 auto;
  overflow: hidden;
  border-radius: var(--radius);
}

figure img { display: block; width: 100%; height: auto; }

.blank-over-logo,
.blank-over-title {
  position: absolute;
  background: #fff;
}

.blank-over-logo {
  top: 1%;
  left: 1%;
  width: 4%;
  height: 2%;
}

.blank-over-title {
  top: 48%;
  left: 34.5%;
  width: 28%;
  height: 5%;
}

figure::after {
  position: absolute;
  right: 0;
  bottom: 0;
  left: 0;
  height: 40%;
  background: linear-gradient(to bottom, transparent 0%, rgba(0, 0, 0, .65) 35%, var(--bg) 75%);
  content: "";
  pointer-events: none;
}

.about {
  width: min(80vw, 1200px);
  margin: 30px auto 0;
  background: var(--bg);
}

.section-heading {
  max-width: 680px;
  margin: 0 0 38px;
}

.section-heading h2 {
  margin: 0;
  font-size: clamp(2rem, 4vw, 3.5rem);
  line-height: 1.1;
  letter-spacing: -.05em;
}

.section-heading > p:last-child {
  max-width: 560px;
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 1.05rem;
}

.features {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.feature {
  display: flex;
  min-width: 0;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}

.feature-copy { padding: 30px 32px 0; }
.feature-number { display: block; margin-bottom: 18px; color: #a6a6a6; font-size: .75rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.feature h3 { margin: 0 0 9px; font-size: clamp(1.45rem, 2.2vw, 1.8rem); letter-spacing: -.035em; }
.feature p { max-width: 400px; margin: 0; color: var(--muted); font-size: .95rem; }

.feature-visual {
  display: grid;
  min-height: 230px;
  flex: 1;
  place-items: center;
  padding: 36px 32px;
}

.voice-visual, .message-visual {
  width: min(100%, 370px);
  border: 1px solid #484848;
  border-radius: var(--radius);
  background: #202020;
}

.visual-header {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 14px 17px;
  border-bottom: 1px solid var(--line);
  color: #ccc;
  font-size: .8rem;
  font-weight: 600;
}

.visual-header svg { width: 16px; height: 16px; color: var(--accent); }
.voice-content { display: flex; align-items: center; gap: 14px; padding: 22px 18px; }
.avatar-stack { display: flex; padding-left: 2px; }
.avatar-stack span {
  display: grid;
  width: 35px;
  height: 35px;
  margin-left: -2px;
  place-items: center;
  border: 2px solid #202020;
  border-radius: 50%;
  background: #d4d4d4;
  color: #303030;
  font-size: .7rem;
  font-weight: 700;
}
.avatar-stack span + span { margin-left: -8px; background: #777; color: #fff; }
.avatar-stack span:last-child { background: #aaa; color: #202020; }

.wave { display: flex; height: 28px; align-items: center; gap: 4px; margin-left: auto; }
.wave span { width: 3px; height: 9px; border-radius: 3px; background: var(--accent); }
.wave span:nth-child(2), .wave span:nth-child(6) { height: 18px; }
.wave span:nth-child(3), .wave span:nth-child(5) { height: 25px; }
.wave span:nth-child(4) { height: 14px; }

.messages { display: grid; gap: 13px; padding: 18px; }
.message-line { display: flex; align-items: start; gap: 10px; }
.message-dot { flex: 0 0 27px; height: 27px; border-radius: 50%; background: #aaa; }
.message-line:nth-child(2) .message-dot { background: #777; }
.message-bars { display: grid; flex: 1; gap: 7px; padding-top: 2px; }
.message-bars span { width: 88%; height: 6px; border-radius: 3px; background: #555; }
.message-bars span:first-child { width: 30%; background: #aaa; }
.message-line:nth-child(2) .message-bars span:last-child { width: 65%; }

.self-hosted-backdrop {
  width: min(80vw, 1200px);
  margin: 16px auto 0;
  background: var(--bg);
}

.self-hosted {
  display: grid;
  grid-template-columns: 1fr minmax(0, .9fr);
  gap: 48px;
  align-items: center;
  width: 100%;
  padding: clamp(32px, 5vw, 64px);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #2c2c2c;
}

.self-hosted h2 {
  max-width: 480px;
  margin: 0;
  font-size: clamp(2rem, 4vw, 3.5rem);
  line-height: 1.1;
  letter-spacing: -.05em;
}

.self-hosted-copy {
  max-width: 480px;
  margin: 18px 0 0;
  color: var(--muted);
  font-size: 1rem;
}

.server-visual {
  display: grid;
  justify-items: center;
  padding: 24px;
  border: 1px solid #484848;
  border-radius: var(--radius);
  background: #202020;
}

.server-node {
  display: flex;
  width: min(100%, 250px);
  align-items: center;
  gap: 12px;
  padding: 14px;
  border: 1px solid #484848;
  border-radius: var(--radius);
  background: #303030;
  color: #e4e4e4;
  font-size: .83rem;
  font-weight: 600;
}

.server-node svg { flex: 0 0 20px; width: 20px; height: 20px; color: var(--accent); }
.server-link { width: 1px; height: 26px; background: #777; }
.server-node + .server-link + .server-node { background: #292929; }

.advantages {
  width: min(80vw, 1200px);
  margin: 100px auto 0;
  background: var(--bg);
}
.advantages-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.advantage {
  min-width: 0;
  padding: 32px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}
.advantage-label {
  display: block;
  margin-bottom: 18px;
  color: #a6a6a6;
  font-size: .75rem;
  font-weight: 700;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.advantage h3 { margin: 0 0 9px; font-size: clamp(1.45rem, 2.2vw, 1.8rem); letter-spacing: -.035em; }
.advantage p { margin: 0; color: var(--muted); font-size: .95rem; }
.ram-chart {
  display: grid;
  gap: 16px;
  margin-top: 24px;
  padding: 18px;
  border: 1px solid #484848;
  border-radius: var(--radius);
  background: #202020;
}
.ram-row > div:first-child { display: flex; justify-content: space-between; gap: 12px; color: #ccc; font-size: .82rem; }
.ram-row strong { color: var(--text); white-space: nowrap; }
.ram-track { height: 5px; margin-top: 8px; overflow: hidden; border-radius: var(--radius); background: #404040; }
.ram-track span { display: block; height: 100%; }
.ram-tawky { width: 2.5%; background: #e5e5e5; }
.ram-other { width: 100%; background: #888; }
.advantage .ram-note { margin-top: 12px; color: #aaa; font-size: .75rem; }
.customization-visual {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 120px;
  gap: 14px;
  margin-top: 24px;
  padding: 18px;
  border: 1px solid #484848;
  border-radius: var(--radius);
  background: #202020;
}
.customization-preview { overflow: hidden; border: 1px solid #484848; border-radius: 5px; background: #292929; }
.customization-banner { height: 58px; background: linear-gradient(125deg, #5c6982, #92847e 55%, #c1a397); }
.customization-profile { display: flex; align-items: center; gap: 10px; padding: 0 12px 12px; }
.customization-avatar { width: 32px; height: 32px; flex: 0 0 32px; margin-top: -12px; border: 3px solid #292929; border-radius: 50%; background: #d3c3b4; }
.customization-lines { display: grid; flex: 1; gap: 6px; padding-top: 10px; }
.customization-lines span { width: 70%; height: 5px; border-radius: 3px; background: #888; }
.customization-lines span + span { width: 45%; background: #555; }
.customization-options { display: grid; align-content: center; gap: 14px; }
.customization-option > span { display: block; margin-bottom: 6px; color: #bcbcbc; font-size: .72rem; font-weight: 600; }
.theme-swatches, .banner-swatches { display: flex; gap: 5px; }
.theme-swatches i { width: 17px; height: 17px; border: 1px solid #777; border-radius: 50%; background: #d4d4d4; }
.theme-swatches i:nth-child(2) { background: #78879f; }
.theme-swatches i:nth-child(3) { background: #a68e81; }
.theme-swatches i:nth-child(4) { background: #667e72; }
.banner-swatches i { width: 28px; height: 14px; border-radius: 2px; background: #78879f; }
.banner-swatches i:nth-child(2) { background: #a68e81; }
.banner-swatches i:nth-child(3) { background: #667e72; }
.customization-free { grid-column: 1 / -1; color: #ccc; font-size: .75rem; font-weight: 700; }

.getting-started {
  width: min(80vw, 1200px);
  margin: 100px auto 0;
  background: var(--bg);
}

.steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.step {
  min-width: 0;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #202020;
}

.step-number {
  display: block;
  margin-bottom: 32px;
  color: #aaa;
  font-size: .75rem;
  font-weight: 700;
  letter-spacing: .08em;
}

.step h3 { margin: 0 0 9px; font-size: 1.2rem; letter-spacing: -.03em; }
.step p { margin: 0; color: var(--muted); font-size: .95rem; }

.downloads {
  width: min(80vw, 1200px);
  margin: 100px auto 76px;
  background: var(--bg);
}

.download-backdrop { background: var(--bg); }
.client-download-backdrop + .server-download-backdrop { margin-top: 16px; }

.download {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  width: 100%;
  padding: 36px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--surface);
}

.download h3 { margin: 0; font-size: clamp(1.3rem, 2.5vw, 1.8rem); letter-spacing: -.035em; }
.download p { margin: 7px 0 0; color: var(--muted); font-size: .93rem; }
.download-action { text-align: center; }
.server-platforms {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.server-platform {
  display: flex;
  min-width: 0;
  align-items: center;
  justify-content: center;
  gap: 3px;
  padding: 7px 2px;
  border: 1px solid #484848;
  border-radius: var(--radius);
  background: #202020;
  color: #ddd;
  font-size: .7rem;
  font-weight: 600;
  cursor: not-allowed;
}
.server-platform svg { flex: 0 0 13px; width: 13px; height: 13px; color: var(--accent); }
.server-release-label { color: #aaa; font-size: .75rem; }
.server-download-action {
  display: flex;
  flex: 0 0 min(350px, 45%);
  min-width: 0;
  flex-direction: column;
  gap: 8px;
  text-align: right;
}
.server-test {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 6px 9px;
  padding-top: 14px;
  border-top: 1px solid #484848;
  font-size: .8rem;
}
.server-test-label {
  padding: 3px 7px;
  border: 1px solid #555;
  border-radius: var(--radius);
  color: #aaa;
  font-size: .72rem;
}
.server-test-link { color: #ccc; cursor: not-allowed; }
.server-test-note { width: 100%; color: #aaa; font-size: .75rem; }
.download .download-action p { margin: 11px 0 0; color: #aaa; font-size: .82rem; }

footer {
  padding: 52px 0 24px;
  border-top: 1px solid var(--line);
  background: var(--bg);
  color: #aaa;
  font-size: .84rem;
}

footer p { margin: 0; }

.footer-main {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) repeat(3, minmax(0, 1fr));
  gap: 32px;
  padding-bottom: 48px;
}

.footer-brand p { max-width: 260px; margin-top: 18px; line-height: 1.6; }
.footer-column h2 { margin: 0 0 18px; color: var(--text); font-size: .85rem; }
.footer-column ul { display: grid; gap: 12px; margin: 0; padding: 0; list-style: none; }
footer a { color: #aaa; text-decoration: none; }
footer a:hover { color: #fff; }
footer a:focus-visible { outline: 2px solid #fff; outline-offset: 4px; }

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
}

.footer-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 12px 24px; }
.developer-credit { display: flex; align-items: center; gap: 7px; }
.developer-link { display: inline-flex; align-items: center; color: var(--text); }
.developer-link img { display: block; width: 84px; height: auto; }

.legal-page {
  width: min(800px, calc(100% - 48px));
  min-height: 55vh;
  margin: 80px auto 100px;
}
.legal-page h1 {
  width: auto;
  height: auto;
  margin: 0 0 24px;
  background: none;
  font-size: clamp(2.4rem, 5vw, 3.8rem);
  line-height: 1.1;
  letter-spacing: -.05em;
}
.legal-page h2 { margin: 36px 0 10px; font-size: 1.25rem; letter-spacing: -.02em; }
.legal-page p, .legal-page li { color: var(--muted); line-height: 1.7; }
.legal-page p { margin: 0 0 14px; }
.legal-page ul { padding-left: 22px; }
.legal-page a { color: var(--text); text-underline-offset: 3px; }
.legal-page a:focus-visible { outline: 2px solid #fff; outline-offset: 3px; }
.legal-page .legal-notice { padding: 16px 18px; border: 1px solid var(--line); border-radius: var(--radius); background: #202020; }

.has-scroll-controls .back-to-top {
  position: fixed;
  z-index: 30;
  right: 24px;
  bottom: 24px;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: #202020;
  color: var(--text);
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity .2s ease;
}

.has-scroll-controls .back-to-top.is-visible {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

@media (prefers-reduced-motion: no-preference) {
  .button { transition: background-color .15s ease, transform .2s ease; }
  .button:hover { transform: translateY(-2px); }
}

@media (max-width: 900px) {
  .server-download { align-items: stretch; flex-direction: column; }
  .server-download-action { flex-basis: auto; width: min(100%, 350px); align-self: flex-end; }
}

@media (max-width: 700px) {
  html { scroll-padding-top: 76px; }
  .wrap { width: calc(100% - 32px); }
  .header-inner { min-height: 66px; }
  .logo-placeholder { width: 88px; height: 26px; }
  .header-nav { gap: 16px; }
  .header-nav a { font-size: .8rem; }
  .language-switch { margin-left: 12px; }
  .hero { padding: 58px 8px 0; }
  h1 { width: 180px; height: 60px; }
  .tagline { margin-top: 15px; }
  .about, .self-hosted-backdrop, .advantages, .getting-started, .downloads { width: calc(100% - 32px); }
  .capture-backdrop { padding-top: 42px; }
  .about { margin-top: 26px; }
  .hero-backdrop::before, .capture-backdrop::before, .about::before, .self-hosted-backdrop::before, .advantages::before, .getting-started::before, .downloads::before, .download-backdrop::before {
    left: -16px;
    right: -16px;
    -webkit-mask-image: linear-gradient(to right, transparent, #000 16px, #000 calc(100% - 16px), transparent);
    mask-image: linear-gradient(to right, transparent, #000 16px, #000 calc(100% - 16px), transparent);
  }
  .capture-backdrop::before {
    left: max(0px, calc((100% - min(80vw, 1200px)) / 2 - 16px));
    right: max(0px, calc((100% - min(80vw, 1200px)) / 2 - 16px));
  }
  .hero-backdrop::before {
    left: -8px;
    right: -8px;
    -webkit-mask-image: linear-gradient(to right, transparent, #000 8px, #000 calc(100% - 8px), transparent);
    mask-image: linear-gradient(to right, transparent, #000 8px, #000 calc(100% - 8px), transparent);
  }
  .section-heading { margin-bottom: 28px; }
  .features { grid-template-columns: 1fr; }
  .feature-copy { padding: 25px 24px 0; }
  .feature-visual { min-height: 190px; padding: 28px 24px; }
  .self-hosted { grid-template-columns: 1fr; gap: 28px; padding: 28px 24px; }
  .advantages { margin-top: 64px; }
  .advantages-grid { grid-template-columns: 1fr; }
  .advantage { padding: 24px; }
  .getting-started { margin-top: 64px; }
  .steps { grid-template-columns: 1fr; }
  .step { padding: 24px; }
  .step-number { margin-bottom: 18px; }
  .downloads { margin-top: 42px; }
  .download { align-items: flex-start; flex-direction: column; padding: 22px; }
  .download-action { width: 100%; }
  .server-download-action { width: min(100%, 350px); }
  .download .button { width: 100%; }
  footer { padding-top: 40px; }
  .footer-main { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 32px 24px; padding-bottom: 36px; }
  .footer-brand { grid-column: 1 / -1; }
  .legal-page { width: calc(100% - 32px); margin: 56px auto 72px; }
  .has-scroll-controls .back-to-top { right: 16px; bottom: 16px; }
}

@media (max-width: 360px) {
  .customization-visual { grid-template-columns: minmax(0, 1fr) 94px; gap: 10px; padding: 12px; }
  .banner-swatches i { width: 24px; }
}

@media (max-width: 600px) {
  .header-nav .nav-features, .header-nav .nav-guide { display: none; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .button { transition: none; }
  header { transition: none; }
  .has-scroll-controls .back-to-top { transition: none; }
}
