@font-face {
  font-family: "Vazirmatn";
  src: url("../fonts/Vazirmatn.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

:root {
  --sidebar-width: 280px;
  --sidebar-collapsed-width: 58px;
  --bg: #f7f9fc;
  --panel: #ffffff;
  --panel-soft: #eef5f4;
  --text: #17202a;
  --muted: #607080;
  --line: #dce5ea;
  --brand: #0f8f83;
  --brand-strong: #07675f;
  --accent: #f0a33a;
  --code: #101820;
  --code-text: #eaf8f6;
  --shadow: 0 18px 50px rgba(23, 32, 42, 0.08);
}

:root.dark {
  --bg: #111719;
  --panel: #172124;
  --panel-soft: #1e3030;
  --text: #edf6f5;
  --muted: #a9bcbd;
  --line: #2c3b40;
  --brand: #41c8b8;
  --brand-strong: #7be0d4;
  --accent: #f5b85a;
  --code: #0b1113;
  --code-text: #e7fffb;
  --shadow: 0 20px 60px rgba(0, 0, 0, 0.28);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  overflow-x: hidden;
  background: var(--bg);
  color: var(--text);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.65;
}

body[dir="rtl"] {
  font-family: "Vazirmatn", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  direction: rtl;
  text-align: right;
}

body[dir="ltr"] {
  direction: ltr;
  text-align: left;
}

body[dir="rtl"] .brand,
body[dir="rtl"] .top-actions,
body[dir="rtl"] .code-window,
body[dir="rtl"] pre,
body[dir="rtl"] code,
body[dir="rtl"] .api-list code,
body[dir="rtl"] .state-list span,
body[dir="rtl"] .card-icon {
  direction: ltr;
}

body[dir="rtl"] code,
body[dir="rtl"] pre,
body[dir="rtl"] .code-window,
body[dir="rtl"] .api-list code,
body[dir="rtl"] .state-list span {
  text-align: left;
  unicode-bidi: isolate;
}

.ltr-text {
  direction: ltr;
  text-align: left;
  unicode-bidi: isolate;
}

a {
  color: inherit;
  text-decoration: none;
}

code,
pre {
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
}

.app-shell {
  min-height: 100vh;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 50;
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 28px;
  gap: 16px;
  background: rgba(247, 249, 252, 0.9);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(18px);
}

:root.dark .topbar {
  background: rgba(17, 23, 25, 0.9);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
  max-width: min(360px, 54vw);
  overflow: hidden;
}

.brand-mark {
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  color: #ffffff;
  background: linear-gradient(135deg, var(--brand), var(--accent));
  font-weight: 800;
}

.brand-logo {
  width: 58px;
  height: 24px;
  display: block;
  object-fit: contain;
  object-position: center;
  flex: 0 0 auto;
}

.brand strong,
.brand small {
  display: block;
  line-height: 1.1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.brand > span {
  min-width: 0;
}

.brand small {
  color: var(--muted);
  font-size: 12px;
  margin-top: 4px;
}

.top-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}

.top-actions a {
  color: var(--muted);
  font-size: 14px;
  font-weight: 600;
  padding: 8px 10px;
}

.icon-btn,
.lang-switch,
.menu-btn {
  border: 1px solid var(--line);
  background: var(--panel);
  color: var(--text);
  border-radius: 8px;
  cursor: pointer;
}

.icon-btn {
  width: 38px;
  height: 38px;
}

.icon-btn .moon {
  display: none;
}

:root.dark .icon-btn .sun {
  display: none;
}

:root.dark .icon-btn .moon {
  display: inline;
}

.lang-switch {
  min-width: 48px;
  height: 38px;
  font-weight: 800;
}

.menu-btn {
  display: none;
  width: 40px;
  height: 38px;
  padding: 8px;
}

.menu-btn span {
  display: block;
  height: 2px;
  margin: 5px 0;
  background: var(--text);
}

.sidebar {
  position: fixed;
  top: 72px;
  bottom: 0;
  width: var(--sidebar-width);
  padding: 24px 18px;
  overflow-y: auto;
  border-inline-end: 1px solid var(--line);
  background: var(--bg);
}

body[dir="ltr"] .sidebar {
  left: 0;
}

body[dir="rtl"] .sidebar {
  right: 0;
}

@media (min-width: 981px) {
  .sidebar {
    top: 0;
    padding-top: 78px;
    z-index: 40;
  }

  .sidebar-home-primary {
    position: sticky;
    top: 0;
    z-index: 2;
    background: var(--bg);
  }

  body[dir="ltr"] .sidebar-section {
    border-radius: 8px;
    overflow: hidden;
    transition: background 160ms ease;
  }

  body[dir="rtl"] .sidebar-section {
    border-radius: 8px;
    overflow: hidden;
    transition: background 160ms ease;
  }

  body[dir="ltr"] .sidebar-section:hover,
  body[dir="ltr"] .sidebar-section:focus-within,
  body[dir="ltr"] .sidebar-section.is-active-section {
    background: var(--panel);
  }

  body[dir="rtl"] .sidebar-section:hover,
  body[dir="rtl"] .sidebar-section:focus-within,
  body[dir="rtl"] .sidebar-section.is-active-section {
    background: var(--panel);
  }

  body[dir="ltr"] .sidebar-section a {
    max-height: 0;
    margin: 0;
    padding-top: 0;
    padding-bottom: 0;
    opacity: 0;
    transform: translateY(-6px);
    overflow: hidden;
    pointer-events: none;
    transition: max-height 180ms ease, padding 180ms ease, opacity 140ms ease, transform 160ms ease;
  }

  body[dir="rtl"] .sidebar-section a {
    max-height: 0;
    margin: 0;
    padding-top: 0;
    padding-bottom: 0;
    opacity: 0;
    transform: translateY(-6px);
    overflow: hidden;
    pointer-events: none;
    transition: max-height 180ms ease, padding 180ms ease, opacity 140ms ease, transform 160ms ease;
  }

  body[dir="ltr"] .sidebar-section:hover a,
  body[dir="ltr"] .sidebar-section:focus-within a,
  body[dir="ltr"] .sidebar-section.is-active-section a {
    max-height: 44px;
    margin: 0;
    padding-top: 9px;
    padding-bottom: 9px;
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
  }

  body[dir="rtl"] .sidebar-section:hover a,
  body[dir="rtl"] .sidebar-section:focus-within a,
  body[dir="rtl"] .sidebar-section.is-active-section a {
    max-height: 44px;
    margin: 0;
    padding-top: 9px;
    padding-bottom: 9px;
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
  }

  body[dir="ltr"] .sidebar-section:hover a:nth-of-type(1),
  body[dir="ltr"] .sidebar-section:focus-within a:nth-of-type(1) {
    transition-delay: 20ms;
  }

  body[dir="rtl"] .sidebar-section:hover a:nth-of-type(1),
  body[dir="rtl"] .sidebar-section:focus-within a:nth-of-type(1) {
    transition-delay: 20ms;
  }

  body[dir="ltr"] .sidebar-section:hover a:nth-of-type(2),
  body[dir="ltr"] .sidebar-section:focus-within a:nth-of-type(2) {
    transition-delay: 70ms;
  }

  body[dir="rtl"] .sidebar-section:hover a:nth-of-type(2),
  body[dir="rtl"] .sidebar-section:focus-within a:nth-of-type(2) {
    transition-delay: 70ms;
  }

  body[dir="ltr"] .sidebar-section:hover a:nth-of-type(3),
  body[dir="ltr"] .sidebar-section:focus-within a:nth-of-type(3) {
    transition-delay: 120ms;
  }

  body[dir="rtl"] .sidebar-section:hover a:nth-of-type(3),
  body[dir="rtl"] .sidebar-section:focus-within a:nth-of-type(3) {
    transition-delay: 120ms;
  }

  body[dir="ltr"] .sidebar-section:hover a:nth-of-type(4),
  body[dir="ltr"] .sidebar-section:focus-within a:nth-of-type(4) {
    transition-delay: 170ms;
  }

  body[dir="rtl"] .sidebar-section:hover a:nth-of-type(4),
  body[dir="rtl"] .sidebar-section:focus-within a:nth-of-type(4) {
    transition-delay: 170ms;
  }

  body[dir="ltr"] .sidebar-section:hover a:nth-of-type(5),
  body[dir="ltr"] .sidebar-section:focus-within a:nth-of-type(5) {
    transition-delay: 220ms;
  }

  body[dir="rtl"] .sidebar-section:hover a:nth-of-type(5),
  body[dir="rtl"] .sidebar-section:focus-within a:nth-of-type(5) {
    transition-delay: 220ms;
  }

  body[dir="ltr"] .sidebar-section:hover a:nth-of-type(6),
  body[dir="ltr"] .sidebar-section:focus-within a:nth-of-type(6) {
    transition-delay: 270ms;
  }

  body[dir="rtl"] .sidebar-section:hover a:nth-of-type(6),
  body[dir="rtl"] .sidebar-section:focus-within a:nth-of-type(6) {
    transition-delay: 270ms;
  }
}

.sidebar-section {
  margin-bottom: 16px;
}

.sidebar-home {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  margin-bottom: 12px;
  padding: 9px 10px;
  color: var(--brand-strong);
  border-radius: 8px;
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.sidebar-home-primary {
  font-size: 15px;
  margin-bottom: 18px;
}

.sidebar-home:hover {
  color: var(--text);
  background: var(--panel-soft);
}

body[dir="rtl"] .sidebar-home {
  letter-spacing: 0;
}

.sidebar-section p {
  margin: 0 0 8px;
  padding: 9px 10px;
  color: var(--brand-strong);
  font-size: 12px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

body[dir="rtl"] .sidebar-section p {
  letter-spacing: 0;
}

.sidebar-section a {
  position: relative;
  display: block;
  padding: 9px 10px;
  color: var(--muted);
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
}

.sidebar-section a:hover {
  color: var(--text);
  background: var(--panel-soft);
}

.sidebar-home.is-active,
.sidebar-section a.is-active {
  color: var(--text);
  background: color-mix(in srgb, var(--brand) 16%, var(--panel));
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--brand) 34%, transparent);
}

.sidebar-section a.is-active {
  font-weight: 800;
  padding-inline-start: 18px;
}

.sidebar-section a.is-active::before {
  content: "";
  position: absolute;
  inset-block: 9px;
  inset-inline-start: 7px;
  width: 3px;
  border-radius: 999px;
  background: var(--brand);
}

.content {
  width: calc(100% - var(--sidebar-width));
  max-width: none;
  padding: clamp(28px, 3.2vw, 56px) clamp(22px, 4.4vw, 86px) 80px;
  min-width: 0;
}

body[dir="ltr"] .content {
  margin-left: var(--sidebar-width);
}

body[dir="rtl"] .content {
  margin-right: var(--sidebar-width);
}

.docs-section {
  width: 100%;
  max-width: 1480px;
  margin-inline: auto;
  scroll-margin-top: 96px;
  margin-bottom: 54px;
  min-width: 0;
}

.hero {
  min-height: min(760px, calc(100vh - 150px));
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(300px, 0.9fr);
  align-items: center;
  gap: clamp(28px, 5vw, 88px);
  padding-bottom: 28px;
}

.eyebrow,
.section-heading span {
  color: var(--brand-strong);
  font-size: 13px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

body[dir="rtl"] .eyebrow,
body[dir="rtl"] .section-heading span {
  letter-spacing: 0;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  margin-bottom: 18px;
  font-size: clamp(2.35rem, 5.2vw, 4.75rem);
  line-height: 1.06;
  letter-spacing: 0;
  overflow-wrap: anywhere;
}

h2 {
  margin-bottom: 12px;
  font-size: clamp(1.85rem, 3.4vw, 2.875rem);
  line-height: 1.1;
  overflow-wrap: anywhere;
}

h3 {
  margin-bottom: 8px;
  font-size: 20px;
}

.hero-copy p,
.section-heading p {
  max-width: 860px;
  color: var(--muted);
  font-size: clamp(1rem, 1.3vw, 1.125rem);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 28px;
}

.primary-btn,
.secondary-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 18px;
  max-width: 100%;
  border-radius: 8px;
  font-weight: 800;
  text-align: center;
}

.primary-btn {
  color: #ffffff;
  background: var(--brand);
}

.secondary-btn {
  color: var(--brand-strong);
  border: 1px solid var(--line);
  background: var(--panel);
}

.hero-panel {
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  box-shadow: var(--shadow);
  min-width: 0;
}

body[dir="rtl"] .hero-panel {
  direction: rtl;
}

.flow-card {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 14px;
  padding: 16px;
  min-height: 68px;
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--bg);
}

.flow-card strong {
  flex: 1;
  min-width: 0;
  line-height: 1.35;
}

body[dir="rtl"] .flow-card {
  direction: rtl;
  flex-direction: row;
  text-align: right;
}

.flow-card span {
  width: 34px;
  height: 34px;
  flex: 0 0 34px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  background: var(--panel-soft);
  color: var(--brand-strong);
  font-size: 12px;
  font-weight: 800;
}

.flow-card.active {
  background: var(--bg);
}

.flow-line {
  width: 2px;
  height: 24px;
  margin: 0 32px;
  background: var(--line);
}

body[dir="rtl"] .flow-line {
  margin-right: 32px;
  margin-left: 0;
}

.grid,
.format-grid,
.check-grid {
  display: grid;
  gap: 16px;
}

.three {
  grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr));
}

.info-card,
.format-grid article {
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
}

.info-card p,
.format-grid p,
.feature-list span {
  color: var(--muted);
}

.card-icon {
  width: 44px;
  height: 34px;
  display: grid;
  place-items: center;
  margin-bottom: 14px;
  border-radius: 8px;
  background: var(--panel-soft);
  color: var(--brand-strong);
  font-size: 12px;
  font-weight: 800;
}

.contact-card {
  display: grid;
  gap: 12px;
}

.info-card code {
  display: inline-block;
  max-width: 100%;
  color: var(--brand-strong);
  overflow-wrap: anywhere;
}

.steps {
  display: grid;
  gap: 12px;
  padding: 0;
  margin: 0 0 20px;
  list-style: none;
  counter-reset: steps;
}

.steps li {
  position: relative;
  padding: 16px 18px 16px 58px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  counter-increment: steps;
}

body[dir="rtl"] .steps li {
  padding: 16px 58px 16px 18px;
}

body[dir="rtl"] .steps.ltr-steps li {
  direction: ltr;
  padding: 16px 18px 16px 58px;
  text-align: left;
}

.steps li::before {
  content: counter(steps);
  position: absolute;
  inset-inline-start: 16px;
  top: 17px;
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  color: #ffffff;
  background: var(--brand);
  font-size: 13px;
  font-weight: 800;
}

.steps strong,
.steps span {
  display: block;
}

.steps span {
  color: var(--muted);
}

.step-with-action {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

body[dir="rtl"] .step-with-action {
  grid-template-columns: minmax(0, 1fr) auto;
}

.step-download-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  max-width: 100%;
  min-height: 38px;
  margin: 0;
  padding: 0 14px;
  border: 1px solid color-mix(in srgb, var(--brand) 46%, var(--line));
  border-radius: 8px;
  color: #ffffff;
  background: var(--brand);
  font-size: 14px;
  font-weight: 800;
}

.step-download-btn:hover {
  background: var(--brand-strong);
}

.code-window {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--code);
  box-shadow: var(--shadow);
}

.cs-viewer {
  border-color: rgba(65, 200, 184, 0.32);
}

.code-title {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 10px 16px;
  color: var(--code-text);
  background: rgba(255, 255, 255, 0.06);
  border-bottom: 1px solid rgba(255, 255, 255, 0.09);
  font-size: 13px;
  font-weight: 800;
  direction: ltr;
  text-align: left;
}

.copy-code-btn {
  margin-left: auto;
  min-height: 30px;
  padding: 0 12px;
  border: 1px solid rgba(65, 200, 184, 0.36);
  border-radius: 8px;
  color: var(--code-text);
  background: rgba(65, 200, 184, 0.12);
  cursor: pointer;
  font: inherit;
  font-size: 12px;
  font-weight: 800;
}

.copy-code-btn:hover {
  background: rgba(65, 200, 184, 0.22);
}

.copy-code-btn:focus-visible {
  outline: 2px solid var(--brand);
  outline-offset: 2px;
}

.file-dot {
  width: 10px;
  height: 10px;
  display: inline-block;
  border-radius: 50%;
  background: var(--brand);
  box-shadow:
    16px 0 0 rgba(240, 163, 58, 0.95),
    32px 0 0 rgba(255, 255, 255, 0.34);
  margin-inline-end: 30px;
  flex: 0 0 auto;
}

pre {
  margin: 0;
  padding: 18px;
  overflow-x: auto;
  color: var(--code-text);
  font-size: 14px;
  line-height: 1.6;
  -webkit-overflow-scrolling: touch;
  max-width: 100%;
}

.cs-viewer pre {
  direction: ltr;
  text-align: left;
  tab-size: 4;
  padding: 0;
}

.cs-viewer code {
  direction: ltr;
  text-align: left;
  unicode-bidi: isolate;
  white-space: pre;
}

.cs-viewer .code-line {
  display: grid;
  grid-template-columns: 46px minmax(0, 1fr);
  min-height: 24px;
  padding-inline-end: 18px;
}

.cs-viewer .code-line::before {
  content: attr(data-line);
  padding-inline-end: 14px;
  color: #858585;
  text-align: right;
  user-select: none;
}

.cs-viewer .code-line:hover {
  background: rgba(255, 255, 255, 0.055);
}

.cs-viewer .code-line span {
  min-width: 0;
}

.cs-viewer .kw {
  color: #569cd6;
}

.cs-viewer .type {
  color: #4ec9b0;
}

.cs-viewer .method {
  color: #dcdcaa;
}

.cs-viewer .str {
  color: #ce9178;
}

.cs-viewer .comment {
  color: #6a9955;
}

.cs-viewer .num,
.cs-viewer .bool {
  color: #b5cea8;
}

.cs-viewer .op {
  color: #d4d4d4;
}

.cs-viewer.compact {
  margin-top: 14px;
  box-shadow: none;
}

.cs-viewer.compact pre {
  font-size: 13px;
}

.feature-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(360px, 100%), 1fr));
  gap: 14px;
}

.feature-list div {
  padding: 18px;
  border-inline-start: 4px solid var(--brand);
  background: var(--panel);
  border-radius: 8px;
}

.feature-list strong,
.feature-list span {
  display: block;
}

.format-grid {
  grid-template-columns: repeat(auto-fit, minmax(min(380px, 100%), 1fr));
}

.format-grid pre {
  margin-top: 14px;
  border-radius: 8px;
  background: var(--code);
}

.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
}

table {
  width: 100%;
  border-collapse: collapse;
}

th,
td {
  padding: 14px 16px;
  border-bottom: 1px solid var(--line);
  text-align: start;
}

th {
  color: var(--brand-strong);
  font-size: 13px;
}

td {
  color: var(--muted);
}

td:first-child {
  color: var(--text);
  font-weight: 700;
}

.split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(min(320px, 100%), 0.8fr);
  gap: 18px;
}

.state-list,
.api-list {
  display: grid;
  gap: 10px;
}

.state-list span,
.api-list code,
.check-grid span {
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
}

.api-list code {
  color: var(--brand-strong);
  overflow-wrap: anywhere;
}

.check-grid {
  grid-template-columns: repeat(auto-fit, minmax(min(340px, 100%), 1fr));
}

.check-grid span::before {
  content: "✓";
  margin-inline-end: 10px;
  color: var(--brand-strong);
  font-weight: 900;
}

.numbered-list {
  display: grid;
  gap: 10px;
  margin: 0;
  padding-left: 24px;
  color: var(--text);
}

.numbered-list li {
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
}

body[dir="rtl"] .numbered-list {
  direction: ltr;
  text-align: left;
}

.faq-list {
  display: grid;
  gap: 12px;
  max-width: 980px;
}

.faq-list details {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--panel);
  overflow: hidden;
}

.faq-list summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 18px;
  color: var(--text);
  cursor: pointer;
  font-weight: 800;
  list-style: none;
}

.faq-list summary::-webkit-details-marker {
  display: none;
}

.faq-list summary::after {
  content: "+";
  flex: 0 0 auto;
  color: var(--brand-strong);
  font-size: 20px;
  line-height: 1;
}

.faq-list details[open] summary::after {
  content: "-";
}

.faq-list p {
  margin: 0;
  padding: 0 18px 18px;
  color: var(--muted);
}

.site-footer {
  width: calc(100% - var(--sidebar-width));
  margin-left: var(--sidebar-width);
  margin-right: 0;
  padding: 34px 42px 28px;
  color: #eef6f5;
  background: #2d3948;
}

body[dir="rtl"] .site-footer {
  margin-left: 0;
  margin-right: var(--sidebar-width);
}

.footer-inner {
  max-width: 1480px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(220px, 100%), 1fr));
  gap: clamp(26px, 6vw, 92px);
}

.footer-links-only {
  max-width: 1320px;
  padding-inline: 12px;
}

.footer-column h2,
.footer-column h3 {
  margin: 0 0 14px;
  color: #ffffff;
  font-size: 16px;
  font-weight: 800;
}

.footer-column h2 {
  font-size: 26px;
}

.footer-column p {
  max-width: 280px;
  margin: 0 0 10px;
  color: #cbd8dc;
}

.footer-column p strong {
  color: #ffffff;
}

.footer-column a {
  display: block;
  width: fit-content;
  max-width: 100%;
  margin: 0 0 8px;
  color: #eef6f5;
  font-weight: 500;
  overflow-wrap: anywhere;
}

.footer-column a:hover {
  color: #7be0d4;
}

.copyright {
  max-width: 1320px;
  margin: 20px auto 0;
  padding-top: 16px;
  color: #dbe6e8;
  text-align: center;
  border-top: none;
}

@media (max-width: 1180px) {
  :root {
    --sidebar-width: 232px;
  }

  .content {
    padding-inline: clamp(22px, 3vw, 36px);
  }

  .site-footer {
    padding-inline: 30px;
  }

  .hero {
    grid-template-columns: minmax(0, 1fr);
    min-height: auto;
    padding-top: 24px;
  }

  .hero-panel {
    max-width: 720px;
  }

}

@media (max-width: 980px) {
  .top-actions a {
    display: none;
  }

  .menu-btn {
    display: block;
  }

  .sidebar {
    transform: translateX(-105%);
    transition: transform 180ms ease;
    z-index: 60;
    box-shadow: var(--shadow);
    background: var(--panel);
  }

  body[dir="rtl"] .sidebar {
    transform: translateX(105%);
  }

  body[dir="ltr"] .sidebar.open,
  body[dir="rtl"] .sidebar.open,
  .sidebar.open {
    transform: translateX(0);
  }

  .content {
    width: 100%;
    margin: 0 !important;
    max-width: none;
    padding: 28px clamp(18px, 4vw, 32px) 64px;
  }

  .site-footer {
    width: 100%;
    margin: 0 !important;
    padding: 34px 20px 24px;
  }

  .footer-inner {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 26px;
  }

  .hero,
  .three,
  .feature-list,
  .format-grid,
  .split,
  .check-grid {
    grid-template-columns: 1fr;
  }

  .hero-actions {
    align-items: stretch;
  }

}

@media (max-width: 560px) {
  .topbar {
    height: auto;
    min-height: 64px;
    padding: 0 14px;
    gap: 8px;
  }

  .brand {
    gap: 9px;
    max-width: calc(100vw - 176px);
  }

  .brand-mark {
    width: 36px;
    height: 36px;
  }

  .brand-logo {
    width: 44px;
    height: 20px;
  }

  .brand small {
    display: none;
  }

  .top-actions {
    gap: 6px;
  }

  .icon-btn,
  .lang-switch,
  .menu-btn {
    height: 36px;
  }

  .icon-btn,
  .menu-btn {
    width: 36px;
  }

  .lang-switch {
    min-width: 42px;
  }

  .sidebar {
    top: 64px;
    width: min(88vw, 310px);
  }

  .content {
    padding: 24px 14px 52px;
  }

  .docs-section {
    margin-bottom: 38px;
    scroll-margin-top: 78px;
  }

  .hero {
    gap: 22px;
  }

  h1 {
    font-size: clamp(2rem, 10vw, 2.55rem);
    line-height: 1.1;
  }

  h2 {
    font-size: clamp(1.55rem, 8vw, 2rem);
  }

  h3 {
    font-size: 1.12rem;
  }

  .hero-copy p,
  .section-heading p {
    font-size: 1rem;
  }

  .primary-btn,
  .secondary-btn {
    width: 100%;
    min-height: 44px;
  }

  .info-card,
  .format-grid article,
  .hero-panel,
  .feature-list div,
  .state-list span,
  .api-list code,
  .check-grid span {
    padding: 16px;
  }

  .steps li {
    padding-block: 14px;
  }

  .step-with-action,
  body[dir="rtl"] .step-with-action {
    grid-template-columns: 1fr;
    align-items: stretch;
  }

  body[dir="rtl"] .step-with-action > div,
  body[dir="rtl"] .step-with-action .step-download-btn {
    justify-self: start;
    max-width: 100%;
  }

  pre {
    padding: 14px;
    font-size: 12.5px;
  }

  th,
  td {
    padding: 12px;
    font-size: 14px;
  }

  .site-footer {
    padding: 30px 16px 22px;
  }

  .footer-inner {
    grid-template-columns: 1fr;
    gap: 22px;
    padding-inline: 0;
  }

  .copyright {
    font-size: 14px;
    text-align: start;
  }
}

@media (max-width: 380px) {
  .brand strong {
    font-size: 15px;
  }

  .content {
    padding-inline: 12px;
  }

  .brand {
    max-width: calc(100vw - 164px);
  }
}
