.app-shell {
  height: 100%;
  display: flex;
  flex-direction: column;
  color: var(--fg);
}


.documents-main {
  flex: 1;
  display: flex;
  min-height: 100vh;
  min-height: 100dvh;
  width: 100%;
  position: relative;
}

.documents-main--sidebar-hidden {
  position: relative;
}

.main-content {
  display: flex;
  flex-direction: column;
  min-height: 0;
  min-width: 0;
  margin: 0;
  border-radius: 0;
  background: var(--surface);
  flex-grow: 1;
  box-shadow: -12px 0 24px -12px var(--shadow-faint);
}

.documents-main:not(.documents-main--sidebar-hidden) .main-content {
  border-left: 1px solid var(--border);
}

.main-content__header {
  padding: 0.5rem 1.25rem;
  justify-content: space-between;
  align-items: center;
  gap: 0.75rem;
}

.main-content__header-wrapper {
  position: relative;
}

.main-content__body {
  position: relative;
  flex: 1 1 auto;
  display: flex;
  min-height: 0;
}

.main-content__body > * {
  min-width: 0;
  min-height: 0;
}

.main-content__body > *:not(.detail-panel) {
  flex: 1 1 auto;
}

.main-content__body--workspace.main-content__body--has-detail > .desk-shell {
  margin-right: calc(-1 * var(--detail-panel-width));
}

.main-content--has-detail {
  padding-right: var(--detail-panel-width);
}

.main-content__title {
  margin: 0;
  font-size: 1rem;
  font-weight: 600;
  color: var(--fg);
}


.documents-main--sidebar-hidden {
  position: relative;
  grid-template-columns: auto minmax(0, 1fr);
}

.sidebar .panel-header .icon,
.main-content__header .icon,
.detail-panel .panel-header .icon {
  width: 1.35rem;
  height: 1.35rem;
}

.main-content__actions {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.main-content__actions-divider {
  display: inline-flex;
  align-items: center;
  color: var(--muted-subtle);
}

.main-content__title {
  margin: 0;
  font-size: 1rem;
  font-weight: 600;
  color: var(--fg);
  display: flex;
  align-items: center;
  gap: 0.5rem;
  min-width: 0;
  flex: 1 1 auto;
  overflow: hidden;
}

.main-content__breadcrumbs {
  flex: 1 1 auto;
  overflow: hidden;
}

.main-content__subtitle {
  font-size: 0.9rem;
  color: var(--muted);
  font-weight: 400;
  line-height: 1.2;
  flex-shrink: 0;
}

.panels-main {
  flex: 1;
  display: flex;
  justify-content: center;
  padding: 1.5rem;
  overflow: auto;
}

.panels-main > * {
  flex: 0 1 720px;
}

.preview-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 0;
}
