:root {
  --theme-color: #1c6b68;
  --docs-accent: #1c6b68;
  --docs-accent-strong: #14514f;
  --docs-accent-soft: rgba(28, 107, 104, 0.12);
  --docs-border: #d9e3e0;
  --docs-border-strong: #c4d1cd;
  --docs-surface: #f6f8f7;
  --docs-panel: #ffffff;
  --docs-panel-muted: #eef3f1;
  --docs-text: #223036;
  --docs-muted: #5d6c72;
  --docs-shadow: 0 12px 30px rgba(20, 34, 41, 0.08);
}

html,
body {
  background: #ffffff;
  color: var(--docs-text);
}

body {
  font-family: "Public Sans", "Segoe UI", sans-serif;
}

.sidebar {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 20px 18px 18px;
  background:
    linear-gradient(180deg, rgba(28, 107, 104, 0.06), rgba(28, 107, 104, 0) 180px),
    var(--docs-surface);
  border-right: 1px solid var(--docs-border);
  z-index: 40;
}

.app-name {
  margin: 0 0 4px;
  padding: 0 8px;
}

.app-name a {
  color: var(--docs-text);
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.sidebar-search {
  position: sticky;
  top: 0;
  z-index: 5;
  padding: 4px 0 0;
  background: linear-gradient(180deg, var(--docs-surface) 84%, rgba(246, 248, 247, 0));
}

.sidebar-search-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
  padding: 0 4px;
  color: var(--docs-muted);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.01em;
}

.sidebar-search-shortcut {
  min-width: 22px;
  padding: 2px 7px;
  border: 1px solid var(--docs-border);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.8);
  color: var(--docs-muted);
  font-size: 0.72rem;
  text-align: center;
}

.sidebar-search-field {
  position: relative;
}

.sidebar-search-input {
  width: 100%;
  border: 1px solid var(--docs-border);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 1px 0 rgba(255, 255, 255, 0.65) inset;
  color: var(--docs-text);
  font: inherit;
  font-size: 0.94rem;
  padding: 12px 14px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.sidebar-search-input:focus {
  outline: none;
  border-color: rgba(28, 107, 104, 0.45);
  background: #ffffff;
  box-shadow: 0 0 0 4px rgba(28, 107, 104, 0.14);
}

.sidebar-search-panel {
  margin-top: 10px;
  overflow: hidden;
  border: 1px solid var(--docs-border);
  border-radius: 18px;
  background: var(--docs-panel);
  box-shadow: var(--docs-shadow);
}

.sidebar-search-results {
  max-height: min(52vh, 480px);
  margin: 0;
  padding: 8px;
  overflow: auto;
  list-style: none;
}

.search-result-item {
  margin: 0;
  padding: 0;
}

.search-result,
.search-empty {
  display: block;
  width: 100%;
  border: 0;
  border-radius: 12px;
  background: transparent;
  color: inherit;
  text-align: left;
}

.search-result {
  cursor: pointer;
  padding: 12px 12px 11px;
}

.search-result:hover,
.search-result.is-selected {
  background: var(--docs-accent-soft);
}

.search-result-title,
.search-result-meta,
.search-result-snippet {
  display: block;
}

.search-result-title {
  font-size: 0.92rem;
  font-weight: 700;
  line-height: 1.35;
}

.search-result-meta {
  margin-top: 3px;
  color: var(--docs-muted);
  font-size: 0.74rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.search-result-snippet {
  margin-top: 6px;
  color: var(--docs-muted);
  font-size: 0.85rem;
  line-height: 1.5;
}

.search-result mark {
  background: rgba(255, 215, 0, 0.28);
  color: inherit;
}

.search-empty {
  padding: 16px 14px;
  color: var(--docs-muted);
  font-size: 0.9rem;
}

.sidebar-nav {
  flex: 1 1 auto;
  min-height: 0;
  padding: 4px 0 12px;
  overflow-y: auto;
}

.sidebar-nav ul {
  margin: 0;
  padding-left: 0;
  list-style: none;
}

.sidebar-nav li {
  margin: 2px 0;
}

.nav-row {
  display: flex;
  align-items: center;
  gap: 6px;
}

.sidebar-nav a {
  flex: 1 1 auto;
  display: block;
  border-radius: 12px;
  color: var(--docs-muted);
  font-size: 0.92rem;
  font-weight: 500;
  line-height: 1.4;
  overflow-wrap: anywhere;
  padding: 9px 12px;
  transition: background 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.sidebar-nav a:hover {
  background: rgba(255, 255, 255, 0.68);
  color: var(--docs-text);
  text-decoration: none;
}

.nav-depth-1 > .nav-row > a {
  color: var(--docs-text);
  font-size: 0.94rem;
  font-weight: 700;
}

.nav-depth-2 > .nav-row > a,
.nav-depth-2 > a {
  font-size: 0.89rem;
}

.nav-depth-3 > .nav-row > a,
.nav-depth-3 > a {
  font-size: 0.84rem;
}

.nav-depth-2,
.nav-depth-3 {
  padding-left: 14px;
}

.nav-depth-3 {
  padding-left: 26px;
}

.nav-group-toggle {
  flex: 0 0 auto;
  width: 30px;
  height: 30px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--docs-muted);
  cursor: pointer;
  transition: background 0.18s ease, color 0.18s ease;
}

.nav-group-toggle:hover,
.nav-group-toggle:focus-visible {
  background: rgba(255, 255, 255, 0.72);
  color: var(--docs-text);
  outline: none;
}

.nav-group-toggle span {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-right: 2px solid currentColor;
  border-bottom: 2px solid currentColor;
  transform: rotate(-45deg);
  transition: transform 0.2s ease;
}

.nav-item.is-open > .nav-row > .nav-group-toggle span {
  transform: rotate(45deg);
}

.nav-children {
  height: 0;
  overflow: hidden;
  transition: height 0.24s ease;
}

.sidebar-nav a.active,
.sidebar-nav a.is-active-link {
  background: rgba(28, 107, 104, 0.16);
  color: var(--docs-accent-strong);
}

.sidebar-nav a.is-active-link {
  box-shadow: inset 3px 0 0 var(--docs-accent);
}

.sidebar-nav a.is-active-trail {
  color: var(--docs-text);
}

.sidebar-toggle {
  z-index: 50;
  border-top-right-radius: 14px;
  background: var(--docs-accent);
  box-shadow: var(--docs-shadow);
}

.markdown-section {
  max-width: 860px;
  color: var(--docs-text);
}

.markdown-section h1,
.markdown-section h2,
.markdown-section h3,
.markdown-section h4 {
  scroll-margin-top: 96px;
  letter-spacing: -0.02em;
}

.markdown-section p,
.markdown-section li {
  color: #334249;
  line-height: 1.75;
}

.markdown-section img {
  max-width: 100%;
  height: auto;
  border-radius: 16px;
  box-shadow: 0 10px 24px rgba(17, 32, 39, 0.08);
}

.markdown-section .handbook-outro {
  margin-top: 40px;
  padding-top: 28px;
  border-top: 1px solid var(--docs-border);
  text-align: center;
}

.markdown-section .handbook-outro p {
  margin: 0 auto 12px;
  max-width: 720px;
}

.markdown-section .handbook-outro-identity {
  color: #364149;
  line-height: 1.55;
}

.markdown-section .handbook-outro-identity strong {
  display: inline-block;
  margin-bottom: 4px;
}

.markdown-section .handbook-outro-links a {
  color: var(--docs-accent);
  font-weight: 600;
  text-decoration: none;
}

.markdown-section .handbook-outro-links a:hover {
  text-decoration: underline;
}

.markdown-section .handbook-outro-summary {
  color: #55636d;
  line-height: 1.65;
}

.markdown-section .handbook-outro-notice {
  margin-top: 20px;
  padding: 18px 20px;
  border: 1px solid var(--docs-border);
  border-radius: 14px;
  background: #f7fbfa;
  text-align: left;
}

.markdown-section .handbook-outro-notice strong {
  display: inline-block;
  margin-bottom: 8px;
  color: #364149;
}

.markdown-section .handbook-outro-notice p {
  margin: 0 0 10px;
  max-width: none;
  color: #55636d;
  line-height: 1.65;
}

.markdown-section .handbook-outro-notice p:last-child {
  margin-bottom: 0;
}

@media screen and (max-width: 768px) {
  .sidebar {
    padding: 18px 16px 24px;
  }

  .sidebar-search {
    padding-top: 10px;
  }

  .markdown-section h1,
  .markdown-section h2,
  .markdown-section h3,
  .markdown-section h4 {
    scroll-margin-top: 108px;
  }

  .nav-depth-2,
  .nav-depth-3 {
    padding-left: 10px;
  }
}
