.app {
  display: flex;
  min-height: 100vh;
}

.app__main {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

.navbar {
  width: 220px;
  flex-shrink: 0;
  background: var(--color-surface);
  border-right: 1px solid var(--color-border);
}

.navbar__inner {
  padding: var(--space-lg) var(--space-md);
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
  min-height: 100%;
}

.navbar__brand {
  font-weight: 700;
  font-size: 18px;
  color: var(--color-fg);
  text-decoration: none;
}

.navbar__auth {
  margin-top: auto;
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
}

.navbar__email {
  font-size: 13px;
  color: var(--color-muted);
  word-break: break-all;
}

.navbar form {
  margin: 0;
}

.navbar .button {
  width: 100%;
  text-align: center;
}

/* Mobile: collapse sidebar into a top bar (--bp-md). */
@media (max-width: 767px) {
  .app {
    flex-direction: column;
    min-height: 100vh;
  }

  .navbar {
    width: 100%;
    border-right: none;
    border-bottom: 1px solid var(--color-border);
  }

  .navbar__inner {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-md);
    padding: var(--space-md);
    min-height: auto;
  }

  .navbar__auth {
    margin-top: 0;
    flex-direction: row;
    align-items: center;
  }

  .navbar .button {
    width: auto;
  }
}
