/* Article layout: left TOC + right content (similar to offline help.html) */
.presscenter .knowledge.article-help-page .container {
  max-width: 1180px;
  overflow: visible;
}

.presscenter .knowledge.article-help-page .category-listings {
  float: none;
  width: 100%;
  margin: 0;
  padding: 0;
  overflow: visible;
}

/* Blog list page: full-width article list, no self-link sidebar */
.presscenter .knowledge.blog-list-page .category-listings {
  float: none;
  width: 100%;
  margin: 0;
}

.article-help-layout {
  --ah-bg: #f6f8fa;
  --ah-card: #ffffff;
  --ah-text: #1f2328;
  --ah-muted: #57606a;
  --ah-border: #d0d7de;
  --ah-accent: #0969da;
  --ah-sidebar-width: 260px;
  --ah-nav-hover: #f0f3f6;
  --ah-sticky-top: 12px;
  display: flex;
  align-items: flex-start;
  gap: 0;
  background: var(--ah-bg);
  border: 1px solid var(--ah-border);
  border-radius: 10px;
  overflow: visible;
}

html {
  scroll-behavior: smooth;
}

.article-help-sidebar {
  position: -webkit-sticky;
  position: sticky;
  top: var(--ah-sticky-top);
  align-self: flex-start;
  width: var(--ah-sidebar-width);
  flex-shrink: 0;
  max-height: calc(100vh - var(--ah-sticky-top) * 2);
  overflow-x: hidden;
  overflow-y: auto;
  background: var(--ah-card);
  border-right: 1px solid var(--ah-border);
  border-radius: 10px 0 0 10px;
  padding: 1rem 0 1.5rem;
  font-size: 13px;
  z-index: 2;
}

.article-help-sidebar-inner {
  padding: 0 0.75rem 0 1rem;
}

.article-help-back {
  display: block;
  margin: 0 0.25rem 0.85rem;
  padding: 0.35rem 0.5rem;
  font-size: 12px;
  font-weight: 500;
  color: var(--ah-accent);
  text-decoration: none;
  border-radius: 6px;
  line-height: 1.45;
}

.article-help-back:hover {
  background: var(--ah-nav-hover);
  color: var(--ah-accent);
  text-decoration: none;
}

.article-help-back:focus-visible {
  outline: 2px solid var(--ah-accent);
  outline-offset: 2px;
}

.article-help-sidebar h2 {
  margin: 0 0 0.35rem;
  font-size: 1.05rem;
  font-weight: 600;
  padding: 0 0.25rem;
  line-height: 1.35;
}

.article-help-sidebar .article-help-meta {
  color: var(--ah-muted);
  font-size: 12px;
  line-height: 1.45;
  margin: 0 0 0.85rem;
  padding: 0 0.25rem;
}

.article-help-sidebar nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.article-help-sidebar nav li {
  margin: 0;
}

.article-help-sidebar nav a {
  display: block;
  padding: 0.38rem 0.5rem 0.38rem 0.65rem;
  color: var(--ah-text);
  text-decoration: none;
  border-radius: 6px;
  border-left: 3px solid transparent;
  line-height: 1.45;
}

.article-help-sidebar nav a:hover {
  background: var(--ah-nav-hover);
  color: var(--ah-accent);
}

.article-help-sidebar nav a:focus-visible {
  outline: 2px solid var(--ah-accent);
  outline-offset: 2px;
}

.article-help-main {
  flex: 1;
  min-width: 0;
  padding: 1.35rem 1.75rem 2rem;
  background: var(--ah-bg);
}

.article-help-main > header {
  margin-bottom: 1.25rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--ah-border);
  scroll-margin-top: calc(var(--ah-sticky-top) + 8px);
}

.article-help-main > header p {
  margin: 0 0 0.75rem;
  text-align: justify;
  line-height: 1.65;
}

.article-help-main > header p:last-child {
  margin-bottom: 0;
}

.article-help-section {
  background: var(--ah-card);
  border: 1px solid var(--ah-border);
  border-radius: 10px;
  padding: 1.25rem 1.4rem;
  margin-bottom: 1rem;
  scroll-margin-top: calc(var(--ah-sticky-top) + 8px);
}

.article-help-section > h2 {
  margin: 0 0 0.75rem;
  font-size: 1.2rem;
  padding-bottom: 0.55rem;
  border-bottom: 1px solid var(--ah-border);
  font-weight: 600;
}

.article-help-section > h3 {
  margin: 1.15rem 0 0.55rem;
  font-size: 1.05rem;
  font-weight: 600;
  line-height: 1.45;
}

.article-help-section > h3:first-of-type {
  margin-top: 0;
}

.article-help-section p {
  margin: 0.55rem 0;
  text-align: justify;
  line-height: 1.65;
}

.article-help-section p:first-of-type {
  margin-top: 0;
}

.article-help-section ul,
.article-help-section ol {
  margin: 0.5rem 0 0.75rem;
  padding-left: 1.35rem;
}

.article-help-section li {
  margin: 0.35rem 0;
  line-height: 1.6;
}

.article-help-section img {
  max-width: 100%;
  height: auto;
  border: 1px solid var(--ah-border);
  border-radius: 4px;
}

.article-help-section .article-help-figure {
  text-align: center;
  margin: 1.25rem 0;
}

.article-help-section code {
  font-family: Consolas, "Segoe UI Mono", monospace;
  font-size: 0.88em;
  background: #f0f3f6;
  padding: 0.12em 0.4em;
  border-radius: 4px;
}

@media (max-width: 960px) {
  .article-help-layout {
    flex-direction: column;
  }

  .article-help-sidebar {
    position: relative;
    top: auto;
    width: 100%;
    max-height: none;
    border-right: none;
    border-radius: 10px 10px 0 0;
    border-bottom: 1px solid var(--ah-border);
  }

  .article-help-main {
    padding: 1.15rem 1rem 1.5rem;
  }
}
