.docs-layout {
  display: flex;
  flex-direction: column;
}

.docs-sidebar {
  display: none;
  height: 0;
  padding: 1rem;
  background: #fff;
  border: 1px solid var(--border);
  border-top: 0px;
  border-radius: 0.375rem;
}

.docs-sidebar.is-open {
  display: block;
  height: auto;
  border-radius: 0rem 0rem 0.4rem 0.4rem;
}

.docs-toggle {
  width: 100%;
  text-align: left;
  font-weight: 600;
  color: #4f46e5; /* purple accent */
  padding: 0.25rem 0;
}

.docs-toggle:hover {
  text-decoration: underline;
}

.docs-subnav {
  list-style: none;
  padding-left: 1rem;
  margin-top: 0.5rem;
}

.docs-subnav li {
  margin: 0.25rem 0;
}

.docs-subnav a {
  text-decoration: none;
  color: #374151;
  font-size: 1rem;
}

.docs-subnav a:hover {
  color: #000;
}

.docs-subnav a.active {
  color: #4f46e5;
  font-weight: 600;
}

.docs-nav {
  list-style: none;
  padding: 0;
  margin: 0;
}

.docs-section {
  margin-bottom: 0.5rem;
}

.docs-sidebar-toggle {
  display: block;
  width: 100%;
  text-align: left;
  padding: 0.75rem 1rem;
  font-weight: 600;
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 0.4rem;
  color: var(--text);
  cursor: pointer;
  margin-top: 2rem;
  font-size: 1rem;
}

.docs-sidebar-toggle[aria-expanded="true"] {
  border-bottom: 0px;
  border-radius: 0.4rem 0.4rem 0px 0px;
}

@media(min-width: 768px) {
  .docs-layout {
    flex-direction: row;
    gap: 2rem;
  }

  .docs-sidebar {
    flex: 0 0 260px;
    display: block;
    position: sticky;
    top: 0px;
    height: calc(100vh - 60px);
    overflow-y: auto;
    width: 260px;
    padding: 1rem;
    border-right: 1px solid #e5e7eb;
    background: #fafafa;
  }

  .docs-sidebar-toggle {
    display: none;
  }
}
