/* Styles for server-rendered Help page */

:root {
  --help-hover: rgba(255, 255, 255, 0.06);
}

body {
  display: flex;
  flex-direction: column;
  height: 100vh;
  overflow: hidden;
  margin: 0;
}

.help-container {
  display: flex;
  flex: 1;
  flex-direction: column;
  min-height: 0;
  padding: 0 0 20px;
  width: min(100% - 48px, var(--container));
  margin: auto;
}

.help-page {
  flex: 1;
  display: flex;
  min-height: 0;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--surface);
}

.help-nav {
  width: 240px;
  flex-shrink: 0;
  border-right: 1px solid var(--border);
  padding: 16px;
  overflow-y: auto;
  background: var(--surface);
}

.help-nav-title {
  margin: 0 0 12px;
  padding: 12px 12px 20px;
  border-bottom: 1px solid var(--border);
  font-size: 16px;
  line-height: 1;
  font-weight: 600;
}

.help-nav-list {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.help-nav-item {
  display: block;
  padding: 8px 12px;
  border-radius: 4px;
  color: var(--text);
  text-decoration: none;
  font-size: 14px;
  transition: background 0.12s;
}

.help-nav-item:hover {
  background: var(--help-hover);
}

.help-nav-item.active {
  background: var(--help-hover);
  font-weight: 600;
}

.help-content {
  flex: 1;
  min-width: 0;
  min-height: 0;
  padding: 32px 40px;
  overflow-y: auto;
  background: var(--bg);
}

.help-content h1 {
  font-size: 1.8em;
  margin: 0 0 0.5em;
}

.help-content h2 {
  font-size: 1.4em;
  margin: 1.2em 0 0.4em;
}

.help-content h3 {
  font-size: 1.15em;
  margin: 1em 0 0.3em;
}

.help-content p {
  margin: 0.6em 0;
  line-height: 1.6;
  color: var(--text);
}

.help-content ul,
.help-content ol {
  padding-left: 1.4em;
  margin: 0.6em 0;
}

.help-content li {
  margin: 0.2em 0;
}

.help-content blockquote {
  border-left: 3px solid var(--border);
  margin: 0.8em 0;
  padding: 0.2em 1em;
  color: var(--text-secondary);
}

.help-content code {
  background: var(--surface);
  border-radius: 4px;
  padding: 0.1em 0.35em;
  font-size: 0.9em;
}

.help-content pre {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px 14px;
  overflow: auto;
  font-size: 13px;
}

.help-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 0.8em 0;
  font-size: 14px;
}

.help-content th,
.help-content td {
  text-align: left;
  padding: 8px 12px;
  border: 1px solid var(--border);
}

.help-content th {
  background: var(--surface);
  font-weight: 600;
}

.help-content hr {
  border: 0;
  border-top: 1px solid var(--border);
  margin: 1.5em 0;
}

.help-content a {
  color: var(--accent);
}

.help-content img {
  max-width: 100%;
  height: auto;
  border-radius: var(--radius);
  cursor: pointer;
}

@media (max-width: 768px) {
  body {
    height: auto;
    overflow-y: auto;
  }

  .help-container {
    flex: none;
    padding: 12px 0;
  }

  .help-page {
    flex: none;
    flex-direction: column;
    min-height: 0;
    overflow: visible;
  }

  .help-nav {
    width: 100%;
    border-right: 0;
    border-bottom: 1px solid var(--border);
  }

  .help-content {
    flex: none;
    overflow-y: visible;
    padding: 16px 20px;
  }
}
