:root {
  --app-sidebar-width: 260px;
  --app-sidebar-width-collapsed: 60px;
  --app-sidebar-space: var(--app-sidebar-width);
  --app-topbar-height: 60px;
}
@media (max-width: 1199.98px) {
  :root {
    --app-sidebar-space: 0px;
  }
}
html.app-sidebar-collapsed {
  --app-sidebar-space: var(--app-sidebar-width-collapsed);
}
.wrap.wrap--with-sidebar {
  padding-top: 0;
  display: flex;
  flex-direction: row;
  align-items: stretch;
  min-height: 100vh;
  min-height: 100dvh;
}
.wrap.wrap--with-sidebar.wrap--guest .app-main-column {
  width: 100%;
}
.app-main-column {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  min-height: 100dvh;
  padding-left: var(--app-sidebar-space);
  transition: padding-left 0.2s ease;
}
.app-topbar {
  flex-shrink: 0;
  min-height: var(--app-topbar-height);
  position: sticky;
  top: 0;
  z-index: 1020;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
}
@media (max-width: 767px) {
  .app-topbar {
    flex-wrap: wrap !important;
  }
}
.app-sidebar-collapse-toggle,
.app-sidebar-mobile-toggle {
  width: 2.25rem;
  height: 2.25rem;
  padding: 0;
}
.app-sidebar-collapse-toggle[aria-pressed="true"] .icon-mask {
  -webkit-mask-image: url("/images/mask/sidebar-right.svg");
          mask-image: url("/images/mask/sidebar-right.svg");
}
@media (min-width: 1200px) {
  .app-sidebar-mobile-toggle {
    display: none;
  }
}
.app-topbar__lead {
  max-width: min(100%, 640px);
}
@media (max-width: 767px) {
  .app-topbar__lead {
    order: 1;
    justify-content: center;
    width: 100%;
  }
}
.app-topbar__title {
  font-family: var(--font-ui);
  font-weight: 400;
  font-size: 22px;
  margin: 0;
  letter-spacing: -0.005em;
  line-height: 1.1;
  color: var(--ink);
}
.app-topbar__actions {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.app-topbar__tail {
  flex-shrink: 0;
}
.app-topbar__center {
  gap: 0.5rem;
}
.app-main-body {
  flex: 1;
  min-height: 0;
  padding: 1.5rem 1.5rem 2.5rem;
}
.app-main-body--editor {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
}
.wrap--with-sidebar .app-main-body--editor > .editor {
  height: auto;
  flex: 1;
  min-height: 0;
}
.app-sidebar {
  width: var(--app-sidebar-width);
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  border-right: 1px solid var(--line);
  background: var(--bg);
  min-height: 100vh;
  min-height: 100dvh;
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  z-index: 1040;
  transition: width 0.2s ease;
  overflow: hidden;
}
html.app-sidebar-collapsed .app-sidebar {
  width: var(--app-sidebar-width-collapsed);
}
.app-sidebar__brand {
  flex-shrink: 0;
  padding: 1.5rem 0;
  margin: 0 0.75rem;
  border-bottom: 1px solid var(--line);
}
.app-sidebar__brand--has-logo {
  padding: 1.125rem 0;
}
.app-sidebar__brand-text {
  font-family: var(--font-ui);
  font-size: 18px;
  letter-spacing: 0.005em;
  line-height: 1.15;
  color: var(--ink);
}
.app-sidebar__brand-link {
  font-family: var(--font-serif);
  font-size: 18px;
  letter-spacing: 0.005em;
  line-height: 1.15;
  color: var(--ink);
  display: flex;
  align-items: center;
  gap: 10px;
}
.app-sidebar__brand-link:hover,
.app-sidebar__brand-link:focus {
  color: hsl(var(--green));
}
.app-sidebar__brand-icon {
  flex-shrink: 0;
}
.app-sidebar__brand-logo {
  width: 36px;
  height: 36px;
  min-width: 36px;
  min-height: 36px;
  -o-object-fit: cover;
     object-fit: cover;
  -o-object-position: center;
     object-position: center;
  border-radius: 8px;
  display: block;
}
html.app-sidebar-collapsed .app-sidebar__brand {
  display: flex;
  justify-content: center;
  margin: 0 0.25rem;
}
html.app-sidebar-collapsed .app-sidebar__brand-text {
  display: none;
}
.app-sidebar__rail {
  display: none;
  flex-direction: column;
  align-items: center;
  gap: 0.375rem;
  padding: 0.75rem 0.5rem;
  flex: 1;
  min-height: 0;
  overflow-y: auto;
}
html.app-sidebar-collapsed .app-sidebar__rail {
  display: flex;
}
html.app-sidebar-collapsed .app-sidebar__expanded {
  display: none;
}
.app-sidebar__rail-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: calc(var(--radius) - 2px);
  color: hsl(var(--foreground));
  text-decoration: none;
  transition: background-color 0.2s, color 0.2s;
}
.app-sidebar__rail-link:hover,
.app-sidebar__rail-link:focus {
  background: var(--bg-2);
  color: var(--ink);
}
.app-sidebar__rail-link.active {
  background: var(--surface);
  color: var(--ink);
  box-shadow: var(--shadow-1);
}
.app-sidebar__rail-link.active .icon-mask {
  background-color: var(--ink);
}
.app-sidebar__expanded {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
  margin-top: 0.625rem;
}
.app-sidebar__scroll {
  flex: 1;
  min-height: 0;
  overflow-y: auto;
}
.app-sidebar__pinned {
  border-bottom: 1px dashed hsl(var(--border));
}
.app-sidebar__link-icon,
.app-sidebar__acc-icon {
  flex-shrink: 0;
}
.app-sidebar__acc-btn {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: var(--radius) !important;
  color: var(--ink-2);
  font-size: 13.5px;
  cursor: pointer;
  position: relative;
  -webkit-user-select: none;
     -moz-user-select: none;
          user-select: none;
  border: 1px solid transparent;
  background: transparent;
  width: 100%;
  text-align: left;
  font-family: var(--font-ui);
}
.app-sidebar__acc-btn:hover,
.app-sidebar__acc-btn:focus {
  background: var(--bg-2);
  color: var(--ink);
}
.app-sidebar__acc-btn:hover .icon-mask,
.app-sidebar__acc-btn:focus .icon-mask {
  background-color: var(--ink);
}
.app-sidebar__acc-btn:not(.collapsed) {
  background: transparent;
  color: var(--ink-2);
  box-shadow: none;
}
.app-sidebar__acc-btn:after {
  width: 12px;
  height: 12px;
  background-size: 12px;
}
.app-sidebar__acc-btn .icon-mask {
  width: 1rem;
  height: 1rem;
  background-color: var(--ink-2);
}
.app-sidebar__acc-label {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: 0.25rem;
}
.app-sidebar__acc-label .show-message-circle:first-of-type {
  margin-left: auto;
}
.app-sidebar__accordion {
  --bs-accordion-bg: transparent;
  --bs-accordion-border-color: hsl(var(--border));
  --bs-accordion-active-bg: transparent;
  --bs-accordion-btn-bg: transparent;
  --bs-accordion-btn-color: hsl(var(--foreground));
  --bs-accordion-active-color: hsl(var(--foreground));
  --bs-accordion-btn-focus-box-shadow: none;
}
.app-sidebar__acc-item {
  border-color: hsl(var(--border));
}
.app-sidebar__subnav {
  flex-direction: column;
  gap: 2px;
  margin: 4px 0 6px;
  padding-left: 32px;
  border-left: 1px dashed var(--line);
  margin-left: 18px;
}
.app-sidebar__subnav-link {
  padding: 6px 10px;
  font-size: 12.5px;
  color: var(--muted);
  cursor: pointer;
  border-radius: var(--radius);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 4px;
}
.app-sidebar__subnav-link:hover,
.app-sidebar__subnav-link:focus {
  background: var(--bg-2);
  color: var(--ink);
}
.app-sidebar__subnav-link.active {
  background: var(--surface);
  color: var(--ink);
  box-shadow: var(--shadow-1);
}
.app-sidebar__subnav-link .show-message-circle:first-of-type {
  margin-left: auto;
}
.app-sidebar__footer {
  flex-shrink: 0;
  padding: 0.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  border-top: 1px dashed hsl(var(--border));
  background-color: hsl(var(--background));
}
.app-sidebar-backdrop {
  position: fixed;
  inset: 0;
  z-index: 1039;
  background: rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(4px);
}
body.app-sidebar-open .app-sidebar-backdrop.d-none {
  display: block !important;
}
@media (max-width: 1199.98px) {
  html.app-sidebar-collapsed {
    --app-sidebar-space: 0px;
  }
  .app-sidebar {
    transform: translateX(-100%);
    transition: transform 0.2s ease, width 0.2s ease;
    box-shadow: var(--elevation-1);
  }
  html.app-sidebar-collapsed .app-sidebar {
    width: var(--app-sidebar-width);
  }
  html.app-sidebar-collapsed .app-sidebar__rail {
    display: none;
  }
  html.app-sidebar-collapsed .app-sidebar__expanded {
    display: flex;
  }
  body.app-sidebar-open .app-sidebar {
    transform: translateX(0);
  }
}
@media (min-width: 1200px) {
  .app-sidebar-backdrop {
    display: none !important;
  }
}
.app-sidebar__acc-item {
  border: none;
  margin: 4px 12px 0;
}
.app-sidebar__acc-item:first-child {
  margin-top: 0;
}
