*, *::before, *::after { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  height: 100%;
  overflow: hidden;
}

.app-shell {
  --sidebar-expanded: 210px;
  --sidebar-collapsed: 56px;
  --sidebar-width: var(--sidebar-expanded);
  display: grid;
  grid-template-columns: var(--sidebar-width) 1fr;
  width: 100vw;
  height: 100vh;
  background: var(--surface2);
  transition: grid-template-columns .18s ease;
}

.app-shell.sidebar-collapsed {
  --sidebar-width: var(--sidebar-collapsed);
}

.app-shell.sidebar-no-transition,
.app-shell.sidebar-no-transition .app-nav {
  transition: none !important;
}

.app-nav {
  grid-column: 1;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 2px;
  padding: 12px 8px;
  background: var(--navy);
  height: 100vh;
  overflow: hidden;
  transition: width .18s ease, padding .18s ease;
}

.app-body {
  grid-column: 2;
  display: flex;
  flex-direction: column;
  height: 100vh;
  min-width: 0;
  overflow: hidden;
}

.app-topbar {
  flex: 0 0 52px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;
  border-bottom: 1px solid var(--border);
  background: var(--surface);
}

.app-content {
  flex: 1 1 0;
  min-height: 0;
  overflow-y: auto;
  padding: 0;
}
