.site-doc {
  padding: clamp(2rem, 4vw, 3.5rem) 0 clamp(5rem, 8vw, 7rem);
}

.default__layout {
  display: grid;
  grid-template-columns: minmax(15rem, 18rem) minmax(0, 1fr);
  gap: clamp(0.75rem, 1.6vw, 1rem);
  align-items: start;
}

.default__content {
  position: relative;
  min-width: 0;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.015), rgba(255, 255, 255, 0.015)),
    linear-gradient(rgba(140, 202, 255, 0.08) 1px, transparent 1px),
    linear-gradient(90deg, rgba(140, 202, 255, 0.08) 1px, transparent 1px);
  background-size: 100% 100%, 100% 1rem, 1rem 100%;
  background-position: center top, center top, center top;
  box-shadow: var(--visual-shadow);
  border: 1px solid var(--panel-border);
  overflow: hidden;
}

.default__toc {
  position: sticky;
  top: calc(var(--header-height) + 0.9rem);
  align-self: start;
  max-height: calc(100vh - var(--header-height) - 1.8rem);
}

.default__toc-inner {
  max-height: calc(100vh - var(--header-height) - 1.8rem);
  padding: 1.2rem 1.1rem;
  background: rgba(17, 17, 24, 0.82);
  border: 1px solid var(--panel-border);
  box-shadow: var(--card-shadow);
  backdrop-filter: blur(14px);
  overflow: auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.16) transparent;
}

.default__toc-eyebrow {
  margin-bottom: 0.9rem;
  color: var(--text-secondary);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.default__toc-list {
  display: grid;
  gap: 0.35rem;
  padding-left: 1.1rem;
}

.default__toc-inner::-webkit-scrollbar {
  width: 0.45rem;
}

.default__toc-inner::-webkit-scrollbar-track {
  background: transparent;
}

.default__toc-inner::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.16);
}

.default__toc-link {
  display: block;
  color: var(--text-secondary);
  font-size: 0.96rem;
  line-height: 1.45;
  text-decoration: none;
  transition: color 180ms ease, opacity 180ms ease, transform 180ms ease;
}

.default__toc-link--active {
  color: var(--text-primary);
  font-weight: 600;
  transform: translateX(0.1rem);
}

.default__toc-link--pending {
  opacity: 0.75;
}

.default__toc-link[href]:hover,
.default__toc-link[href]:focus-visible {
  color: var(--text-primary);
  opacity: 1;
}

.default__header {
  position: relative;
  padding: clamp(1.6rem, 3vw, 2.6rem);
  overflow: hidden;
}

.default__header-shell {
  position: relative;
  z-index: 1;
  display: grid;
  justify-items: end;
  text-align: right;
}

.default__header-eyebrow {
  margin-bottom: 1rem;
  color: var(--accent-3);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.default__header-title,
.default__header-intro {
  margin-left: auto;
}

.default__header-title {
  margin-bottom: 1.15rem;
  color: var(--text-primary);
  font-size: clamp(2.2rem, 5vw, 4rem);
  line-height: 1.02;
  letter-spacing: -0.04em;
}

.default__header-intro {
  max-width: 62ch;
  color: var(--text-secondary);
  font-size: clamp(1rem, 1.4vw, 1.1rem);
  line-height: 1.8;
}

.default__header::after {
  content: "";
  position: absolute;
  left: clamp(1.4rem, 3vw, 2.2rem);
  right: clamp(1.4rem, 3vw, 2.2rem);
  bottom: 0;
  height: 12px;
  background:
    linear-gradient(
      90deg,
      color-mix(in srgb, var(--accent-3) 0%, transparent) 0%,
      color-mix(in srgb, var(--accent-3) 26%, transparent) 18%,
      color-mix(in srgb, var(--accent-3) 44%, transparent) 50%,
      color-mix(in srgb, var(--accent-3) 26%, transparent) 82%,
      color-mix(in srgb, var(--accent-3) 0%, transparent) 100%
    ),
    linear-gradient(
      90deg,
      color-mix(in srgb, var(--accent-3) 0%, transparent) 0%,
      color-mix(in srgb, var(--accent-3) 16%, transparent) 18%,
      color-mix(in srgb, var(--accent-3) 28%, transparent) 50%,
      color-mix(in srgb, var(--accent-3) 16%, transparent) 82%,
      color-mix(in srgb, var(--accent-3) 0%, transparent) 100%
    );
  background-repeat: no-repeat;
  background-size: 100% 2px, 100% 2px;
  background-position: center calc(50% - 2.5px), center calc(50% + 2.5px);
  pointer-events: none;
}

.default__section {
  padding: clamp(1.4rem, 3vw, 2.2rem);
}

.default__section-shell {
  position: relative;
}

.default__section-eyebrow {
  margin-bottom: 1rem;
  color: var(--text-muted);
  font-size: 0.74rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

:root[data-theme="dark"] .default__section-eyebrow {
  color: color-mix(in srgb, var(--text-primary) 72%, var(--accent-3));
}

.default__section-title {
  margin-bottom: 0.5rem;
  color: var(--text-primary);
  font-size: clamp(1.45rem, 2.8vw, 2.2rem);
  line-height: 1.15;
  letter-spacing: -0.03em;
}

.default__section-body {
  width: 100%;
  max-width: none;
  font-size: 1rem;
  line-height: 1.8;
  text-align: justify;
  text-justify: inter-word;
  text-wrap: pretty;
  color: color-mix(in srgb, var(--text-primary) 78%, var(--text-secondary));
  font-weight: 450;
  text-indent: 1.1rem;
}

.default__section-body + .default__section-body {
  margin-top: 1rem;
}

.default__section-subtitle {
  margin: 1.2rem 0 0.55rem;
  color: var(--text-primary);
  font-size: 1.02rem;
  line-height: 1.4;
  letter-spacing: -0.01em;
}

.default__section-body code,
.default__section-list-item code {
  display: inline-block;
  margin: 0 0.08rem;
  padding: 0.06rem 0.18rem 0.08rem;
  border: 1px solid color-mix(in srgb, var(--accent-3) 28%, var(--panel-border));
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--accent-3) 20%, transparent), transparent),
    color-mix(in srgb, var(--surface-2) 90%, var(--surface-1));
  color: color-mix(in srgb, var(--text-primary) 92%, white);
  box-shadow:
    inset 0 1px 0 color-mix(in srgb, white 10%, transparent),
    0 0 0 1px color-mix(in srgb, var(--accent-3) 10%, transparent);
  font-family: "Fira Code", monospace;
  font-size: 0.92em;
  font-weight: 600;
  line-height: 1.3;
  letter-spacing: 0;
  text-align: left;
  text-indent: 0;
  direction: ltr;
  unicode-bidi: isolate;
  font-variant-ligatures: none;
  white-space: nowrap;
  vertical-align: baseline;
}

.default__section-body strong + code,
.default__section-list-item strong + code,
.default__section-body code + code,
.default__section-list-item code + code {
  margin-left: 0.28rem;
}

.default__section-list {
  margin: 1rem 0;
  padding-left: 1.85rem;
  display: grid;
  gap: 0.45rem;
  color: color-mix(in srgb, var(--text-primary) 78%, var(--text-secondary));
}

.default__section-list-item {
  line-height: 1.75;
}

.default__section-list-item::marker {
  color: var(--accent-3);
  font-weight: 700;
}

.default__section-list-item p {
  margin: 0.2rem 0 0;
}

.default__section-list + .default__section-body {
  margin-top: 1rem;
}

.default__faq-list {
  display: grid;
  gap: 0.9rem;
}

.default__faq-item {
  border: 1px solid color-mix(in srgb, var(--panel-border) 82%, var(--accent-3));
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--accent-3) 6%, transparent), transparent 22%),
    color-mix(in srgb, var(--surface-2) 96%, var(--surface-1));
  box-shadow: 0 18px 34px rgba(8, 10, 15, 0.1);
  overflow: hidden;
}

.default__faq-item[open] {
  border-color: color-mix(in srgb, var(--accent-3) 34%, var(--panel-border));
}

.default__faq-question {
  position: relative;
  display: block;
  padding: 1rem 3rem 1rem 1.2rem;
  color: var(--text-primary);
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.6;
  cursor: pointer;
  list-style: none;
}

.default__faq-question::-webkit-details-marker {
  display: none;
}

.default__faq-question::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 0.22rem;
  background: linear-gradient(180deg, color-mix(in srgb, var(--accent-3) 96%, white), color-mix(in srgb, var(--accent-3) 54%, transparent));
  opacity: 0.88;
}

.default__faq-question::after {
  content: "+";
  position: absolute;
  top: 50%;
  right: 1.15rem;
  transform: translateY(-50%);
  color: color-mix(in srgb, var(--accent-3) 82%, var(--text-primary));
  font-size: 1.2rem;
  font-weight: 500;
}

.default__faq-item[open] .default__faq-question::after {
  content: "−";
}

.default__faq-answer {
  padding: 0 1.2rem 1.1rem 1.2rem;
}

.default__faq-answer p {
  margin: 0;
  color: var(--text-secondary);
  line-height: 1.78;
}

:root[data-theme="light"] .default__toc-inner {
  background: rgba(255, 255, 255, 0.82);
}

:root[data-theme="light"] .default__section-body code,
:root[data-theme="light"] .default__section-list-item code {
  background:
    linear-gradient(180deg, rgba(37, 99, 235, 0.08), transparent),
    rgba(255, 255, 255, 0.94);
  border-color: color-mix(in srgb, var(--accent-3) 22%, rgba(15, 23, 42, 0.08));
  color: color-mix(in srgb, var(--text-primary) 88%, #0f172a);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.85),
    0 1px 2px rgba(15, 23, 42, 0.06);
}

:root[data-theme="light"] .default__faq-item {
  background:
    linear-gradient(180deg, rgba(37, 99, 235, 0.04), transparent 22%),
    rgba(255, 255, 255, 0.98);
  box-shadow: 0 18px 34px rgba(104, 78, 58, 0.08);
}

:root[data-theme="light"] .default__content {
  background:
    linear-gradient(180deg, rgba(15, 23, 42, 0.012), rgba(15, 23, 42, 0.012)),
    linear-gradient(rgba(36, 99, 235, 0.07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(36, 99, 235, 0.07) 1px, transparent 1px);
  background-size: 100% 100%, 100% 1rem, 1rem 100%;
  background-position: center top, center top, center top;
}

:root[data-theme="light"] .default__toc-inner {
  scrollbar-color: rgba(22, 29, 37, 0.18) transparent;
}

:root[data-theme="light"] .default__toc-inner::-webkit-scrollbar-thumb {
  background: rgba(22, 29, 37, 0.18);
}

@media (max-width: 980px) {
  .default__layout {
    grid-template-columns: 1fr;
  }

  .default__toc {
    position: static;
    max-height: none;
  }

  .default__toc-inner {
    position: static;
    max-height: none;
  }

  .default__toc-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.5rem 0.9rem;
  }
}


@media (max-width: 720px) {
  .site-doc {
    padding-top: 1.25rem;
  }

  .default__toc-list {
    grid-template-columns: 1fr;
  }

  .default__header-shell {
    justify-items: end;
    text-align: right;
  }

  .default__header-title,
  .default__header-intro {
    margin-left: auto;
  }

  .default__header-intro,
  .default__section-title {
    max-width: none;
  }

  .default__section-body code,
  .default__section-list-item code {
    white-space: normal;
    word-break: break-word;
  }

  .default__faq-question {
    padding: 0.95rem 2.8rem 0.95rem 1rem;
  }

  .default__faq-answer {
    padding: 0 1rem 1rem 1rem;
  }

}
