.app-shell { min-height: 100vh; }
.app-header {
  position: fixed;
  inset: 0 0 auto 0;
  z-index: 80;
  height: var(--header-h);
  display: grid;
  grid-template-columns: var(--sidebar-w) minmax(0, 1fr) auto;
  align-items: center;
  border-bottom: 1px solid var(--border);
  background: var(--surface);
  backdrop-filter: blur(18px) saturate(1.3);
}
.header-left, .header-center, .header-right { height: 100%; display: flex; align-items: center; }
.header-left { padding: 0 22px; border-right: 1px solid var(--border); }
.header-center { padding: 0 24px; gap: 14px; }
.header-right { padding: 0 18px; justify-content: flex-end; gap: 8px; white-space: nowrap; }

.workspace {
  display: grid;
  grid-template-columns: var(--sidebar-w) minmax(0, 1fr) var(--outline-w);
  min-height: 100vh;
  padding-top: var(--header-h);
}
.sidebar {
  position: fixed;
  top: var(--header-h);
  bottom: 0;
  left: 0;
  width: var(--sidebar-w);
  overflow-y: auto;
  border-right: 1px solid var(--border);
  background: var(--bg);
}

.sidebar::-webkit-scrollbar {
    width: 2px;
    height: 1px;
}


.main-content {
  grid-column: 2;
  min-width: 0;
  padding: 46px clamp(28px, 5vw, 72px) 84px;
}
.content-container { width: min(100%, var(--content-max)); margin: 0 auto; }
.page-outline {
  position: fixed;
  top: var(--header-h);
  right: 0;
  bottom: 0;
  width: var(--outline-w);
  overflow-y: auto;
  border-left: 1px solid var(--border);
  background: var(--bg);
  padding: 36px 24px;
}
.app-footer {
  position: relative;
  z-index: 2;
  margin-left: var(--sidebar-w);
  margin-right: var(--outline-w);
  border-top: 1px solid var(--border);
  background: var(--bg-subtle);
}
.footer-inner {
  width: min(calc(100% - 64px), 1180px);
  margin: 0 auto;
  padding: 34px 0;
  display: grid;
  grid-template-columns: 1.3fr repeat(3, minmax(120px, 1fr));
  gap: 36px;
}
.footer-bottom {
  width: min(calc(100% - 64px), 1180px);
  margin: 0 auto;
  padding: 16px 0 24px;
  border-top: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  color: var(--text-muted);
  font-size: 13px;
}
